forked from github/server
check for dead curse-magician
This commit is contained in:
parent
3715f21e6c
commit
ff7cd7d20d
|
@ -1091,7 +1091,7 @@ variant magic_resistance(unit * target)
|
||||||
c = (curse *)a->data.v;
|
c = (curse *)a->data.v;
|
||||||
mage = c->magician;
|
mage = c->magician;
|
||||||
|
|
||||||
if (mage != NULL) {
|
if (mage != NULL && mage->number > 0) {
|
||||||
if (good_resist && c->type == &ct_goodmagicresistancezone) {
|
if (good_resist && c->type == &ct_goodmagicresistancezone) {
|
||||||
if (alliedunit(mage, target->faction, HELP_GUARD)) {
|
if (alliedunit(mage, target->faction, HELP_GUARD)) {
|
||||||
/* TODO: legacy. magicresistance-effect is an integer-percentage stored in a double */
|
/* TODO: legacy. magicresistance-effect is an integer-percentage stored in a double */
|
||||||
|
|
Loading…
Reference in New Issue