mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-29 23:07:48 +02:00
Support simturn timers
This commit is contained in:
@@ -300,7 +300,7 @@ void CServerHandler::applyPacksOnLobbyScreen()
|
|||||||
CPackForLobby * pack = packsForLobbyScreen.front();
|
CPackForLobby * pack = packsForLobbyScreen.front();
|
||||||
packsForLobbyScreen.pop_front();
|
packsForLobbyScreen.pop_front();
|
||||||
CBaseForLobbyApply * apply = applier->getApplier(typeList.getTypeID(pack)); //find the applier
|
CBaseForLobbyApply * apply = applier->getApplier(typeList.getTypeID(pack)); //find the applier
|
||||||
apply->applyOnLobbyScreen(static_cast<CLobbyScreen *>(SEL), this, pack);
|
apply->applyOnLobbyScreen(dynamic_cast<CLobbyScreen *>(SEL), this, pack);
|
||||||
GH.windows().totalRedraw();
|
GH.windows().totalRedraw();
|
||||||
delete pack;
|
delete pack;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -149,6 +149,10 @@ void TurnTimerWidget::tick(uint32_t msPassed)
|
|||||||
updateTimer(PlayerColor::NEUTRAL, msPassed);
|
updateTimer(PlayerColor::NEUTRAL, msPassed);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
if(LOCPLINT->makingTurn)
|
||||||
|
updateTimer(LOCPLINT->playerID, msPassed);
|
||||||
|
else
|
||||||
{
|
{
|
||||||
for(PlayerColor p(0); p < PlayerColor::PLAYER_LIMIT; ++p)
|
for(PlayerColor p(0); p < PlayerColor::PLAYER_LIMIT; ++p)
|
||||||
{
|
{
|
||||||
@@ -156,4 +160,5 @@ void TurnTimerWidget::tick(uint32_t msPassed)
|
|||||||
updateTimer(p, msPassed);
|
updateTimer(p, msPassed);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user