You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to listen for multiple variations of a command using hears()? For example, I'd like to be able to listen for:
mycommand action (.*)
and
action (.*)
Using | to separate the commands seems to allow execution, though when using regex in both of the commands, the text doesn't seem to come through as expected.
Version: ^2.1
Is it possible to listen for multiple variations of a command using
hears()
? For example, I'd like to be able to listen for:mycommand action (.*)
and
action (.*)
Using
|
to separate the commands seems to allow execution, though when using regex in both of the commands, the text doesn't seem to come through as expected.Example Code
When the bot hears
command action [message]
,$message
comes through without any issues. When the bot hearsaction [message]
,$message
is empty.As long as there's not regex, both command variants work, though I need regex in 99% of the commands in use. Perhaps I'm just doing it wrong :).
The text was updated successfully, but these errors were encountered: