Fix check for opponent side for mana drain
This commit is contained in:
1 parent
51b7de4b98
commit
296310e32e
2 files changed
+5
-6
No files matched your search
@@ -677,8 +677,7 @@ void BattleFlowProcessor::stackTurnTrigger(const CBattleInfoCallback & battle, c
|
||||
}
|
||||
if(st->hasBonusOfType(BonusType::MANA_DRAIN) && !st->drainedMana)
|
||||
{
|
||||
const PlayerColor opponent = battle.otherPlayer(battle.battleGetOwner(st));
|
||||
const CGHeroInstance * opponentHero = battle.battleGetFightingHero(opponent);
|
||||
const CGHeroInstance * opponentHero = battle.battleGetFightingHero(battle.otherSide(st->unitSide()));
|
||||
if(opponentHero)
|
||||
{
|
||||
ui32 manaDrained = st->valOfBonuses(BonusType::MANA_DRAIN);
|
||||
|
||||
Reference in new issue
Block a user