mirror of
https://github.com/vcmi/vcmi.git
synced 2025-12-07 23:33:15 +02:00
Next part of town configuration:
- town screen is mostly implemented, has some minor issues - factions are now separate from towns, neutrals have faction with id=9 - more constants to GameConstants: town-specific buildings, strings for terrains and resources - replaced most access to builtBuildings with isBuilt() method - replaced id's with enums for town subtype and buildings id's
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#include "../lib/JsonNode.h"
|
||||
#include "../lib/Filesystem/CResourceLoader.h"
|
||||
#include "../lib/map.h"
|
||||
#include "../lib/CModHandler.h"
|
||||
#include "../lib/CObjectHandler.h"
|
||||
#include "../lib/CGameState.h"
|
||||
#include "../lib/CGeneralTextHandler.h"
|
||||
@@ -294,7 +295,7 @@ void CTownList::CTownItem::update()
|
||||
if (!town->hasFort())
|
||||
iconIndex += GameConstants::F_NUMBER*2;
|
||||
|
||||
if(town->builded >= GameConstants::MAX_BUILDING_PER_TURN)
|
||||
if(town->builded >= CGI->modh->settings.MAX_BUILDING_PER_TURN)
|
||||
iconIndex++;
|
||||
|
||||
picture->setFrame(iconIndex + 2);
|
||||
|
||||
Reference in New Issue
Block a user