From acd88377a918439972819d57c9c6e15d695473fc Mon Sep 17 00:00:00 2001 From: Jacob Mandelson Date: Wed, 14 Feb 2024 11:09:39 -0800 Subject: [PATCH 1/2] Calculate tidalsize before using it in mouseovers. This way the game doesn't immediately crash when restoring a save in tidal areas. --- help.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/help.cpp b/help.cpp index 240b2f6e..5b0868ce 100644 --- a/help.cpp +++ b/help.cpp @@ -881,6 +881,7 @@ EX void describeMouseover() { if(shmup::on) out += " (" + its(c->landparam)+")"; else { + calcTidalPhase(); bool b = c->landparam >= tide[(turncount-1) % tidalsize]; int t = 1; for(; t < 1000 && b == (c->landparam >= tide[(turncount+t-1) % tidalsize]); t++) ; From 08a774dfd469e5a852ca12249ba022e718c85e2f Mon Sep 17 00:00:00 2001 From: Jacob Mandelson Date: Sat, 17 Feb 2024 20:48:58 -0800 Subject: [PATCH 2/2] Record Orb of Fish in savefile. --- system.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/system.cpp b/system.cpp index 1fbdb837..eb615d40 100644 --- a/system.cpp +++ b/system.cpp @@ -443,7 +443,7 @@ EX namespace scores { /** \brief the amount of boxes reserved for each hr::score item */ #define MAXBOX 500 /** \brief currently used boxes in hr::score */ -#define POSSCORE 408 +#define POSSCORE 410 /** \brief a struct to keep local score from an earlier game */ struct score { /** \brief version used */ @@ -941,6 +941,9 @@ EX void applyBoxes() { applyBoxEnum(bow::weapon, "weapon choice"); applyBoxEnum(bow::style, "crossbow style"); + applyBoxOrb(itOrbFish); + list_invorb(); + if(POSSCORE != boxid) printf("ERROR: %d boxes\n", boxid); if(isize(invorb)) { println(hlog, "ERROR: Orbs not taken into account"); exit(1); } }