mirror of
https://github.com/vcmi/vcmi.git
synced 2025-07-01 00:45:26 +02:00
CGSubterraneanGate: fix pairing and always assign all gates to channel
Before gates on underground layer didn't had any channel assigned and of course any function that attempt to check -1 channel caused crash. Also I find out that at point postInit executed It's possible to get mutable gamestate via gameState() callback so we don't need to pass it there.
This commit is contained in:
@ -1867,7 +1867,7 @@ void CGameState::initMapObjects()
|
||||
}
|
||||
}
|
||||
}
|
||||
CGSubterraneanGate::postInit(gs); //pairing subterranean gates
|
||||
CGSubterraneanGate::postInit(); //pairing subterranean gates
|
||||
|
||||
map->calculateGuardingGreaturePositions(); //calculate once again when all the guards are placed and initialized
|
||||
}
|
||||
|
Reference in New Issue
Block a user