(svn r12757) -Codechange: move all cheat related stuff from all over the place to a single location.

This commit is contained in:
rubidium
2008-04-17 21:21:01 +00:00
parent 5050ba84fb
commit b1d1a4ac66
23 changed files with 420 additions and 285 deletions

View File

@@ -14,6 +14,7 @@
#include "network/network.h"
#include "network/network_internal.h"
#include "variables.h"
#include "cheat_func.h"
#include "ai/ai.h"
#include "player_face.h"
#include "group.h"
@@ -956,19 +957,6 @@ StringID EndGameGetPerformanceTitleFromValue(uint value)
return _endgame_perf_titles[value];
}
/** Return true if any cheat has been used, false otherwise */
static bool CheatHasBeenUsed()
{
const Cheat* cht = (Cheat*)&_cheats;
const Cheat* cht_last = &cht[sizeof(_cheats) / sizeof(Cheat)];
for (; cht != cht_last; cht++) {
if (cht->been_used) return true;
}
return false;
}
/** Save the highscore for the player */
int8 SaveHighScoreValue(const Player *p)
{