1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

integrate campaign intro

This commit is contained in:
Laserlicht
2024-08-31 17:57:27 +02:00
parent 9c2a5f6baa
commit 46872b764b
8 changed files with 54 additions and 4 deletions

View File

@@ -204,8 +204,8 @@ void ApplyOnLobbyScreenNetPackVisitor::visitLobbyUpdateState(LobbyUpdateState &
if(!lobby->bonusSel && handler.si->campState && handler.getState() == EClientState::LOBBY_CAMPAIGN)
{
lobby->bonusSel = std::make_shared<CBonusSelection>();
if(!handler.si->campState->conqueredScenarios().size())
GH.windows().createAndPushWindow<CampaignIntroVideo>(VideoPath::builtin("Hc1_Intro"), ImagePath::builtin("INTRORIM"), lobby->bonusSel);
if(!handler.si->campState->conqueredScenarios().size() && !handler.si->campState->getIntroVideo().empty())
GH.windows().createAndPushWindow<CampaignIntroVideo>(handler.si->campState->getIntroVideo(), handler.si->campState->getIntroVideoRim().empty() ? ImagePath::builtin("INTRORIM") : handler.si->campState->getIntroVideoRim(), lobby->bonusSel);
else
GH.windows().pushWindow(lobby->bonusSel);
}