1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-26 03:52:01 +02:00

Fixed #407 (it doesn't matter that banks battle won't freeze immediately)

This commit is contained in:
DjWarmonger 2010-03-02 18:13:22 +00:00
parent c3cf16df19
commit 6a756cf882

View File

@ -4799,15 +4799,16 @@ void CBank::setPropertyDer (ui8 what, ui32 val)
switch (bc->guards.size())
{
case 1:
for (int i = 0; i <= 4; i++)
army.setCreature (i, bc->guards[0].first + upgraded, bc->guards[0].second / 5 );
for (int i = 0; i < 4; ++i)
army.setCreature (i, bc->guards[0].first, bc->guards[0].second / 5 );
army.setCreature (4, bc->guards[0].first + upgraded, bc->guards[0].second / 5 );
break;
case 4:
{
std::vector< std::pair <ui16, ui32> >::const_iterator it;
for (it = bc->guards.begin(); it != bc->guards.end(); it++)
{
int n = army.slots.size(); //debug
int n = army.slots.size();
army.setCreature (n, it->first, it->second);
}
}