X-Git-Url: https://jxself.org/git/?p=open-adventure.git;a=blobdiff_plain;f=main.c;h=b131190cb58e91f1c0bd6aa51d87fd5b5542a4e1;hp=e8625b2978c4529aa945b05a3d5de977a2d5f20b;hb=09cd426443517901dfc45de2fbe939d935c94158;hpb=0590c080eec764cc8d50e8c8875a4ecd9ff76ff9 diff --git a/main.c b/main.c index e8625b2..b131190 100644 --- a/main.c +++ b/main.c @@ -465,7 +465,7 @@ static void croak(void) /* Okay, he's dead. Let's get on with it. */ { if (game.numdie < 0) - game.numdie = 0; + game.numdie = 0; // LCOV_EXCL_LINE const char* query = obituaries[game.numdie].query; const char* yes_response = obituaries[game.numdie].yes_response; ++game.numdie; @@ -1041,7 +1041,7 @@ Lclearobj: game.oldobj = command.obj; command.obj = 0; -L2600: +Lcheckhint: checkhints(); /* If closing time, check for any objects being toted with @@ -1185,9 +1185,6 @@ Lookup: default: // LCOV_EXCL_LINE BUG(VOCABULARY_TYPE_N_OVER_1000_NOT_BETWEEN_0_AND_3); // LCOV_EXCL_LINE } - if (!is_valid(game)) { - exit(1); - } switch (action(command)) { case GO_TERMINATE: return true; @@ -1199,11 +1196,7 @@ Lookup: case GO_CLEAROBJ: goto Lclearobj; case GO_CHECKHINT: - goto L2600; - case GO_CHECKFOO: - goto Lclosecheck; - case GO_LOOKUP: - goto Lookup; + goto Lcheckhint; case GO_WORD2: #ifdef GDEBUG printf("Word shift\n"); @@ -1218,7 +1211,7 @@ Lookup: command.word[0].raw[0] = toupper(command.word[0].raw[0]); sspeak(DO_WHAT, command.word[0].raw); command.obj = 0; - goto L2600; + goto Lcheckhint; case GO_DWARFWAKE: /* Oh dear, he's disturbed the dwarves. */ rspeak(DWARVES_AWAKEN);