1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

Silence "X doesn't have a base stack!" warning

This commit is contained in:
AlexVinS 2016-11-18 15:52:45 +03:00
parent 931656f24a
commit 6d13c8938c

View File

@ -271,6 +271,8 @@ public:
assert (hero);
base = hero->commander;
}
else if(slot == SlotID::WAR_MACHINES_SLOT || slot == SlotID::ARROW_TOWERS_SLOT)
base = nullptr;
else if(!army || slot == SlotID() || !army->hasStackAtSlot(slot))
{
base = nullptr;