1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-23 22:37:55 +02:00

Huge optimization based on profiling - cut generation time by almost half (Jebus XL+U).

This commit is contained in:
DjWarmonger
2016-08-09 10:12:13 +02:00
parent 08dccb4cc3
commit 7f0b852449
4 changed files with 43 additions and 14 deletions

View File

@@ -94,12 +94,16 @@ public:
ui32 getZoneCount(TFaction faction);
ui32 getTotalZoneCount() const;
TRmgTemplateZoneId getZoneID(const int3& tile) const;
void setZoneID(const int3& tile, TRmgTemplateZoneId zid);
private:
std::map<TRmgTemplateZoneId, CRmgTemplateZone*> zones;
std::map<TFaction, ui32> zonesPerFaction;
ui32 zonesTotal; //zones that have their main town only
CTileInfo*** tiles;
boost::multi_array<TRmgTemplateZoneId, 3> zoneColouring; //[z][x][y]
int prisonsRemaining;
//int questArtsRemaining;