From 5350f049b26a613fe80d3f2e0d2a4a021c2513d8 Mon Sep 17 00:00:00 2001 From: PatR Date: Tue, 12 Oct 2021 11:41:56 -0700 Subject: [PATCH] remove unused globals: save_cm, was_waterlevel From entrez. Since restoring was removed separately it was easier to edit the files manually than to use his diff. --- include/decl.h | 2 -- src/cmd.c | 8 ++------ src/decl.c | 2 -- 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/include/decl.h b/include/decl.h index 87b5a4874..97bb2b17a 100644 --- a/include/decl.h +++ b/include/decl.h @@ -772,7 +772,6 @@ struct instance_globals { stairway *stairs; int smeq[MAXNROFROOMS + 1]; int doorindex; - char *save_cm; long done_money; long domove_attempting; long domove_succeeded; @@ -997,7 +996,6 @@ struct instance_globals { /* mkmaze.c */ lev_region bughack; /* for preserving the insect legs when wallifying * baalz level */ - boolean was_waterlevel; /* ugh... this shouldn't be needed */ struct bubble *bbubbles; struct bubble *ebubbles; struct trap *wportal; diff --git a/src/cmd.c b/src/cmd.c index 0c29a41d3..521b42b5e 100644 --- a/src/cmd.c +++ b/src/cmd.c @@ -4502,13 +4502,9 @@ parse(void) } g.multi = g.command_count; - - if (g.multi) { + if (g.multi) g.multi--; - g.save_cm = g.command_line; - } else { - g.save_cm = (char *) 0; - } + /* in 3.4.3 this was in rhack(), where it was too late to handle M-5 */ if (g.Cmd.pcHack_compat) { /* This handles very old inconsistent DOS/Windows behaviour diff --git a/src/decl.c b/src/decl.c index 1cd1042d3..0c5c1c389 100644 --- a/src/decl.c +++ b/src/decl.c @@ -262,7 +262,6 @@ const struct instance_globals g_init = { NULL, /* stairs */ DUMMY, /* smeq */ 0, /* doorindex */ - NULL, /* save_cm */ 0, /* done_money */ 0L, /* domove_attempting */ 0L, /* domove_succeeded */ @@ -466,7 +465,6 @@ const struct instance_globals g_init = { /* mkmaze.c */ { {COLNO, ROWNO, 0, 0}, {COLNO, ROWNO, 0, 0} }, /* bughack */ - FALSE, /* was_waterlevel */ UNDEFINED_PTR, /* bbubbles */ UNDEFINED_PTR, /* ebubbles */ UNDEFINED_PTR, /* wportal */