From: Jason S. Ninneman Date: Tue, 11 Jul 2017 15:52:50 +0000 (-0700) Subject: Replace tests on packed words with tests on strings. X-Git-Tag: 1.3~135 X-Git-Url: https://jxself.org/git/?p=open-adventure.git;a=commitdiff_plain;h=b5e8eec80e027b9d2e4e6ca7c4d8c6ebdbfc1570 Replace tests on packed words with tests on strings. --- diff --git a/main.c b/main.c index f24c5bc..8f3549e 100644 --- a/main.c +++ b/main.c @@ -1137,11 +1137,11 @@ Lclosecheck: command.wd1 = token_to_packed("CATCH"); } Lookup: - if (wordeq(command.wd1, token_to_packed("WEST"))) { + if (strncasecmp(command.raw1, "west", sizeof("west")) == 0) { if (++game.iwest == 10) rspeak(W_IS_WEST); } - if (wordeq(command.wd1, token_to_packed("GO")) && !wordempty(command.wd2)) { + if (strncasecmp(command.raw1, "go", sizeof("go")) == 0 && !wordempty(command.wd2)) { if (++game.igo == 10) rspeak(GO_UNNEEDED); }