Is there is a way to “intercept” and react to a specific entry? As in, if the player writes a certain thing I can write a reaction.
The reason I ask is that I want to deal with “climb dumpster” but I already have things set for climb, and climb is an existing command too.
Basically, instead of doing a whole bunch of coding for a single entry I’d like to return a response.
The interpreter doesn’t understand:
instead of climbing dumpster:
say "You can't do that.".
Hmm, that rule should compile and behave as intended – and out of the box, you shouldn’t even need to write something like that because in the Standard Rules, attempts to climb something are blocked with the message “Little is to be achieved by that.” Are you getting a compiler error keyed to that rule? If so, what’s the error say? Or is it compiling and you’re not getting the behavior you want?
Either way I suspect there’s something in how you’ve defined your new climb action that’s causing trouble, so might be helpful to share the action definition too.
(Oh, and as to your original question, there are ways to do this – the simplest would probably be something like:
Understand "climb [dumpster]" as a mistake ("You can't do that").
But it’s usually a bad idea to do things this way – bypassing the action processing rules can lead to unintended behavior and make things confusing for the player to boot).
Just checking for one specific kind of bug: are any of your climb rules “check climbing” or “before climbing”? Because those will always happen before an instead rule.
DING DING DING!
Yes! Good work @mathbrush. That’s the issue.
Great! I have no idea how I figured it (It certainly because I made that same mistake three times in the last month)