X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=actions.c;h=fdf2319023732c79b8ea27b75d42b88468351619;hb=f52a78a1f8ce3f2bbf6728d6d1e4fc517afeddac;hp=5de7cb001e4a7b276ccc19c8f0e96bd05539e470;hpb=63152e67145eb22371a45a4ae6d3ba35bd221847;p=open-adventure.git diff --git a/actions.c b/actions.c index 5de7cb0..fdf2319 100644 --- a/actions.c +++ b/actions.c @@ -171,7 +171,7 @@ static int bigwords(token_t foo) * Look up foo in special section of vocab to determine which word we've got. * Last word zips the eggs back to the giant room (unless already there). */ { - char word[6]; + char word[TOKLEN+1]; packed_to_token(foo, word); int k = (int) get_special_vocab_id(word); int spk = NOTHING_HAPPENS; @@ -983,7 +983,7 @@ static int read(struct command_t command) } if (DARK(game.loc)) { - rspeak(NO_SEE, command.wd1, command.wd1x); + sspeak(NO_SEE, command.raw1); } 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 (objects[command.obj].texts[0] == NULL || @@ -1043,7 +1043,7 @@ static int say(struct command_t *command) b = command->wd2x; command->wd1 = command->wd2; } - char word1[6]; + char word1[TOKLEN+1]; packed_to_token(command->wd1, word1); int wd = (int) get_vocab_id(word1); /* FIXME: magic numbers */ @@ -1240,7 +1240,7 @@ int action(struct command_t *command) command->verb == INVENTORY) && command->wd2 <= 0) /* FALL THROUGH */; else { - rspeak(NO_SEE, command->wd1, command->wd1x); + sspeak(NO_SEE, command->raw1); return GO_CLEAROBJ; } @@ -1437,7 +1437,7 @@ int action(struct command_t *command) } case unknown: /* Unknown verb, couldn't deduce object - might need hint */ - rspeak(WHAT_DO, command->wd1, command->wd1x); + sspeak(WHAT_DO, command->raw1); return GO_CHECKHINT; default: BUG(SPEECHPART_NOT_TRANSITIVE_OR_INTRANSITIVE_OR_UNKNOWN); // LCOV_EXCL_LINE