Skip to content

Free games for graphing calculators: NumWorks, TI-Nspire CX, Casio fx-CG50 and soon TI-84 Plus CE. Balatro, Celeste, Hollow Knight, Minecraft and more.

4 Players: the app test checks the save its copy brings back

Mason363e108db506509
diff --git a/games/fourplayer/src/app.c b/games/fourplayer/src/app.c
index 661b14b7..8f577e8c 100644
--- a/games/fourplayer/src/app.c
+++ b/games/fourplayer/src/app.c
@@ -119,7 +119,7 @@ enum { S_MODE, S_GAMES, S_RULES, S_PLAY, S_SCORE, S_OVER, S_PAUSE, S_ASK };
#define SCORE_MS 3000 /* the scores between rounds */
static struct {
int screen, sel, under; /* under: the screen under Paused or Quit game? */
- int cur, last_cur; /* the game playing, the one before (Mix) */
+ int cur; /* the game playing */
int nsides, score[4], round, winner, matches; /* winner: the round's side, -1 a draw */
bool decided, started, dirty;
int32_t end_t, freeze; /* freeze: ms of countdown left after Resume */
diff --git a/tests/test_games.py b/tests/test_games.py
index 42edf15d..119ccd66 100644
--- a/tests/test_games.py
+++ b/tests/test_games.py
@@ -747,8 +747,10 @@ CHECKS = {
"amongus": (lambda v: v[:4] == b"AUSG" and v[4] == 1,) * 2,
# "IMPS", version 1: the players and the round; after the reinstall, from the copy, the same
"imposter": (lambda v: v[:4] == b"IMPS" and v[4] == 1,) * 2,
- # "FOUR", version 1, its size (188): 4 players (5), Sumo (6), first to 3 (7); after the reinstall, from the copy
- "fourplayer": (lambda v: len(v) == 188 and v[:4] == b"FOUR" and v[4:8] == bytes([1, 2, 0, 3]),) * 2,
+ # "FOUR", version 1, its size (188): 4 players (5), Sumo (6), first to 3 (7); after the reinstall, from the copy,
+ # Down chose 2 v 2
+ "fourplayer": (lambda v: len(v) == 188 and v[:4] == b"FOUR" and v[4:8] == bytes([1, 2, 0, 3]),
+ lambda v: len(v) == 188 and v[:4] == b"FOUR" and v[4:8] == bytes([1, 3, 0, 3])),
"breakout": (lambda v: len(v) == 12 and v[:2] == b"B\2" and v[4] == 1 and struct.unpack_from("<I", v, 8)[0] >= 10,
lambda v: v[4] == 0 and struct.unpack_from("<I", v, 8)[0] >= 1), # best kept, shake off
# Air Hockey and the easy computer chosen; then the normal computer and Tanks, the tallies of the six games kept