|
|
@@ -805,7 +805,7 @@ CTownItem::CTownItem(const CGTownInstance * Town)
|
|
|
picture = std::make_shared<CAnimImage>(AnimationPath::builtin("ITPT"), iconIndex, 0, 5, 6);
|
|
|
openTown = std::make_shared<LRClickableAreaOpenTown>(Rect(5, 6, 58, 64), town);
|
|
|
|
|
|
- for(size_t i=0; i<town->creatures.size(); i++)
|
|
|
+ for(size_t i=0; i<town->creatures.size() && i<GameConstants::CREATURES_PER_TOWN; i++)
|
|
|
{
|
|
|
growth.push_back(std::make_shared<CCreaInfo>(Point(401+37*(int)i, 78), town, (int)i, true, true));
|
|
|
available.push_back(std::make_shared<CCreaInfo>(Point(48+37*(int)i, 78), town, (int)i, true, false));
|