diff --git a/classes.h b/classes.h index 61ce5d0a..9ba31d96 100644 --- a/classes.h +++ b/classes.h @@ -221,6 +221,8 @@ enum eGeometryClass { gcHyperbolic, gcEuclid, gcSphere, gcSol, gcNil, gcProduct enum class eVariation { bitruncated, pure, goldberg, irregular, dual }; +typedef flagtype modecode_t; + struct geometryinfo { const char* tiling_name; const char* quotient_name; diff --git a/hyper.h b/hyper.h index 5aae6097..9670eae8 100644 --- a/hyper.h +++ b/hyper.h @@ -419,8 +419,6 @@ typedef function cellfunction; #define YDIST 101 #define MODECODES (1ll<<61) -typedef flagtype modecode_t; - #define GUNRANGE 3 // loops diff --git a/system.cpp b/system.cpp index aefe3709..f40462a0 100644 --- a/system.cpp +++ b/system.cpp @@ -902,7 +902,7 @@ EX void saveStats(bool emergency IS(false)) { if((tactic::on || yendor::on) && !items[itOrbSafety] && !cheater) { int t = (int) (timer - timerstart); - ll xcode = modecode(); + modecode_t xcode = modecode(); if(tactic::on) { int score = items[treasureType(specialland)]; @@ -913,7 +913,7 @@ EX void saveStats(bool emergency IS(false)) { int(xcode)*999 + tactic::id + 256 * score + (xcode>>32)*7); fprintf(f, "TACTICS %s %d %d %d %d %d %d %d %d date: %s\n", VER, tactic::id, specialland, score, turncount, t, int(timerstart), - c, xcode, buf); + c, int(xcode), buf); tactic::record(specialland, score); anticheat::nextid(tactic::id, VER, c); } @@ -924,7 +924,7 @@ EX void saveStats(bool emergency IS(false)) { yendor::lastchallenge, items[itOrbYendor], yendor::won, turncount, t, int(timerstart), anticheat::certify(yendor::won ? "WON" : "LOST", turncount, t, (int) timerstart, int(xcode)*999 + yendor::lastchallenge + 256 * items[itOrbYendor] + (xcode>>32)*7), - xcode, + int(xcode), buf); fclose(f); diff --git a/yendor.cpp b/yendor.cpp index 28a6d46d..04a28872 100644 --- a/yendor.cpp +++ b/yendor.cpp @@ -1054,6 +1054,8 @@ int modecodetable[42][6] = { // unused codes: 6 (cheat/tampered), 25, 254, 255 modecode_t modecode() { + // bit 61: product + if(prod) return PIU(modecode()) | (1ll << 61); #if CAP_SAVE if(anticheat::tampered || cheater || geometry >= gGUARD) return 6; #endif