I know how to replace “You can’t see any thing” with a custom message, but i would very much like to have different custom messages for different actions. Is there any way to do this? I have tried using the usual parser error rule and then checking the current action, but that doesn’t seem to work.
There’s quite likely a solution that I’m overlooking, maybe using one of the extensions, but would this do what you want?
[code]To decide what action-name is the action-to-be: (- action_to_be -).
Rule for printing a parser error when the parser error is can’t see
any such thing and the action-to-be is taking:
say “Can’t take what ain’t here.”
Rule for printing a parser error when the parser error is can’t see
any such thing and the action-to-be is eating:
say “Can’t eat what ain’t here.” [/code]
etc.
(zarf showed me the action_to_be thing.)
NB I don’t recommend these error messages; they’re those unfriendly-to-newbie error messages people complain about, which assume the player and not the parser is making a mistake.