1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-13 01:20:34 +02:00

- filesystem.json files for wog and vcmi data

- merged puzzle map into town configuration (todo: sieges, adventure map, icons)
This commit is contained in:
Ivan Savenko
2012-09-20 21:28:18 +00:00
parent 656cf5ab6a
commit 99dcb73a72
14 changed files with 629 additions and 568 deletions

View File

@ -5018,14 +5018,16 @@ CPuzzleWindow::CPuzzleWindow(const int3 &GrailPos, double discoveredRatio):
int faction = LOCPLINT->cb->getStartInfo()->playerInfos.find(LOCPLINT->playerID)->second.castle;
for(int g=0; g<PUZZLES_PER_FACTION; ++g)
auto & puzzleMap = CGI->townh->factions[faction].puzzleMap;
for(int g=0; g<puzzleMap.size(); ++g)
{
const SPuzzleInfo & info = CGI->heroh->puzzleInfo[faction][g];
const SPuzzleInfo & info = puzzleMap[g];
auto piece = new CPicture(info.filename, info.x, info.y);
//piece that will slowly disappear
if(info.whenUncovered < PUZZLES_PER_FACTION * discoveredRatio)
if(info.whenUncovered < GameConstants::PUZZLE_MAP_PIECES * discoveredRatio)
{
piecesToRemove.push_back(piece);
piece->needRefresh = true;