From: Eric S. Raymond Date: Mon, 11 Jan 2021 05:14:51 +0000 (-0500) Subject: Attempt fix for issue #52: endgame oyster reading is incorrect X-Git-Tag: 1.10~25 X-Git-Url: https://jxself.org/git/?p=open-adventure.git;a=commitdiff_plain;h=747c42029df74710034eff07316e91cf8c6e1444 Attempt fix for issue #52: endgame oyster reading is incorrect --- diff --git a/actions.c b/actions.c index f38f9e5..9917199 100644 --- a/actions.c +++ b/actions.c @@ -1105,8 +1105,14 @@ static phase_codes_t read(command_t command) if (DARK(game.loc)) { sspeak(NO_SEE, command.word[0].raw); - } else if (command.obj == OYSTER && !game.clshnt && game.closed) { - game.clshnt = yes(arbitrary_messages[CLUE_QUERY], arbitrary_messages[WAYOUT_CLUE], arbitrary_messages[OK_MAN]); + } else if (command.obj == OYSTER) { + if (!TOTING(OYSTER) || !game.closed) { + rspeak(DONT_UNDERSTAND); + } else if (!game.clshnt) { + game.clshnt = yes(arbitrary_messages[CLUE_QUERY], arbitrary_messages[WAYOUT_CLUE], arbitrary_messages[OK_MAN]); + } else if (game.clshnt) { + pspeak(OYSTER, hear, true, 1); // Not really a sound, but oh well. + } } else if (objects[command.obj].texts[0] == NULL || game.prop[command.obj] == STATE_NOTFOUND) { speak(actions[command.verb].message);