1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-09-16 09:26:28 +02:00

Merge pull request #1155 from Nordsoft91/fix-camp-919

Fix for #919
This commit is contained in:
Andrii Danylchenko
2022-11-25 11:43:25 +02:00
committed by GitHub
2 changed files with 4 additions and 0 deletions

View File

@@ -1387,6 +1387,8 @@ static void handleEvent(SDL_Event & ev)
{
if(ourCampaign->mapsRemaining.size())
{
GH.pushInt(CMM);
GH.pushInt(CMM->menu);
CMM->openCampaignLobby(ourCampaign);
}
};

View File

@@ -2857,6 +2857,8 @@ void CGameState::replaceHeroesPlaceholders(const std::vector<CGameState::Campaig
heroToPlace->tempOwner = heroPlaceholder->tempOwner;
heroToPlace->pos = heroPlaceholder->pos;
heroToPlace->type = VLC->heroh->objects[heroToPlace->subID];
heroToPlace->appearance = VLC->objtypeh->getHandlerFor(Obj::HERO,
heroToPlace->type->heroClass->getIndex())->getTemplates().front();
for(auto &&i : heroToPlace->stacks)
i.second->type = VLC->creh->objects[i.second->getCreatureID()];