1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-12 02:28:11 +02:00

Fixed crash when unit dies by entering obstacle (eg. moat) on the way to perform attack.

This commit is contained in:
Michał W. Urbańczyk 2012-09-30 17:48:21 +00:00
parent 099e6bf776
commit 3de9b71cc3

View File

@ -3404,6 +3404,7 @@ bool CGameHandler::makeBattleAction( BattleAction &ba )
}
//attack
if(stack->alive()) //move can cause death, eg. by walking into the moat
{
BattleAttack bat;
prepareAttack(bat, stack, stackAtEnd, distance, ba.additionalInfo);