prevent an invalid assert when undead heroes are magical

This commit is contained in:
Enno Rehling 2014-12-07 11:14:14 +01:00
parent 66f733e105
commit 3dd3761acd
1 changed files with 2 additions and 1 deletions

View File

@ -1190,7 +1190,8 @@ skill *add_skill(unit * u, skill_t id)
sv->old = 0; sv->old = 0;
sv->id = id; sv->id = id;
if (id == SK_MAGIC && u->faction && !fval(u->faction, FFL_NPC)) { if (id == SK_MAGIC && u->faction && !fval(u->faction, FFL_NPC)) {
assert(u->number==1 && max_magicians(u->faction) >= u->number); assert(u->number<=1);
assert(max_magicians(u->faction) >= u->number);
} }
return sv; return sv;
} }