mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
add persistent storage & completed campaign support
This commit is contained in:
@@ -107,6 +107,9 @@ CCampaignScreen::CCampaignButton::CCampaignButton(const JsonNode & config, std::
|
||||
auto header = CampaignHandler::getHeader(campFile);
|
||||
hoverText = header->getName();
|
||||
|
||||
if(persistent["campaign"][campaignSet][header->getFilename()]["completed"].Bool())
|
||||
status = CCampaignScreen::COMPLETED;
|
||||
|
||||
if(status != CCampaignScreen::DISABLED)
|
||||
{
|
||||
addUsedEvents(LCLICK | HOVER);
|
||||
|
||||
Reference in New Issue
Block a user