1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

Show quest description only after visit

This commit is contained in:
Ivan Savenko 2023-11-02 15:59:03 +02:00
parent d7d8177390
commit 2f3d14da5c

View File

@ -531,14 +531,16 @@ std::string CGSeerHut::getPopupText(const CGHeroInstance * hero) const
std::vector<Component> CGSeerHut::getPopupComponents(PlayerColor player) const
{
std::vector<Component> result;
quest->mission.loadComponents(result, nullptr);
if (quest->activeForPlayers.count(player))
quest->mission.loadComponents(result, nullptr);
return result;
}
std::vector<Component> CGSeerHut::getPopupComponents(const CGHeroInstance * hero) const
{
std::vector<Component> result;
quest->mission.loadComponents(result, hero);
if (quest->activeForPlayers.count(hero->getOwner()))
quest->mission.loadComponents(result, hero);
return result;
}