AlexVinS пре 8 година
родитељ
комит
3ce238e4d3
1 измењених фајлова са 3 додато и 3 уклоњено
  1. 3 3
      client/battle/CBattleInterface.cpp

+ 3 - 3
client/battle/CBattleInterface.cpp

@@ -3104,12 +3104,12 @@ void CBattleInterface::showHighlightedHexes(SDL_Surface *to)
                 if(spellToCast)//hero casts spell
                 if(spellToCast)//hero casts spell
 				{
 				{
 					spell = SpellID(spellToCast->additionalInfo).toSpell();
 					spell = SpellID(spellToCast->additionalInfo).toSpell();
-					caster = activeStack->side == BattleSide::ATTACKER ? attackingHeroInstance : defendingHeroInstance;
+					caster = getActiveHero();
 				}
 				}
 				else if(creatureSpellToCast >= 0 && stackCanCastSpell && creatureCasting)//stack casts spell
 				else if(creatureSpellToCast >= 0 && stackCanCastSpell && creatureCasting)//stack casts spell
 				{
 				{
-                    spell = SpellID(creatureSpellToCast).toSpell();
-                    caster = activeStack;
+					spell = SpellID(creatureSpellToCast).toSpell();
+					caster = activeStack;
 				}
 				}
 
 
 				if(caster && spell) //when casting spell
 				if(caster && spell) //when casting spell