mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 01:59:43 +01:00
Add function Game::anything_unlocked()
This will be a useful shorthand to ask "do we have the Secret Lab, or any Time Trial, or Intermission replays, or No Death Mode, or Flip Mode unlocked?"
This commit is contained in:
parent
dc2adea8ee
commit
833bbdbbef
2 changed files with 18 additions and 0 deletions
|
@ -7313,3 +7313,20 @@ int Game::crewmates()
|
|||
}
|
||||
return temp;
|
||||
}
|
||||
|
||||
bool Game::anything_unlocked()
|
||||
{
|
||||
for (size_t i = 0; i < unlock.size(); i++)
|
||||
{
|
||||
if (unlock[i] &&
|
||||
(i == 8 // Secret Lab
|
||||
|| i >= 9 || i <= 14 // any Time Trial
|
||||
|| i == 16 // Intermission replays
|
||||
|| i == 17 // No Death Mode
|
||||
|| i == 18)) // Flip Mode
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -286,6 +286,7 @@ public:
|
|||
|
||||
std::vector<int> unlock;
|
||||
std::vector<int> unlocknotify;
|
||||
bool anything_unlocked();
|
||||
int stat_trinkets;
|
||||
bool fullscreen;
|
||||
int bestgamedeaths;
|
||||
|
|
Loading…
Reference in a new issue