mirror of
https://github.com/vcmi/vcmi.git
synced 2025-06-19 00:17:56 +02:00
Add some diagnostics for inablilty to place all stacks on battlefield
This commit is contained in:
@ -85,6 +85,12 @@ void CRewardableObject::battleFinished(IGameEventCallback & gameEvents, const CG
|
||||
{
|
||||
if (result.winner == BattleSide::ATTACKER)
|
||||
{
|
||||
while(!stacks.empty())
|
||||
{
|
||||
logMod->warn("Attacker won, but defender still has remaining units in configurable map objects! Make sure that guards configuration is valid!");
|
||||
gameEvents.eraseStack(StackLocation(id, stacks.begin()->first));
|
||||
}
|
||||
|
||||
doHeroVisit(gameEvents, hero);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user