1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-27 22:49:25 +02:00

- Added missing abilities for devil & ghost dragon

- Stack affected by Berserk should not try to attack itself

Neither of these can be actually seen in game duo to more general engine bugs :/
This commit is contained in:
DjWarmonger
2013-04-27 06:39:59 +00:00
parent 0f7d175896
commit 32c87f532f
6 changed files with 22 additions and 9 deletions

View File

@@ -5780,8 +5780,8 @@ void CGameHandler::runBattle()
}
if(next->hasBonusOfType(Bonus::ATTACKS_NEAREST_CREATURE)) //while in berserk
{
std::pair<const CStack *, int> attackInfo = curB.getNearestStack(next, boost::logic::indeterminate);
{ //fixme: stack should not attack itself
std::pair<const CStack *, int> attackInfo = curB.getNearestStack(next, boost::logic::indeterminate, true);
if(attackInfo.first != NULL)
{
BattleAction attack;