Help with custom command

Asked Apr 18, 2020·1 reply·Last activity 6 years ago·Open in Discord ↗
Archived from the original community forum
Things may have changed since it was written. Still stuck? Ask the community on Discord.

I would like to create a command where the bot sends a message in the chat whenever a message in the chat contains a certain word, regardless of where it is written in the message. Example:

Chat: bla bla bla -the word- bla bla bla

Nightbot: -show message-

Chat: -a word- bla bla bla

Nightbot: -show message-

Chat: bla bla bla -the word-

Nightbot: -show message-

The closest I got was to create a command where if the chat message contains ONLY the word in question, the bot responds, but that does not satisfy my need.

Could someone please help me?

1 reply

This isn’t possible since by design a command only triggers if its name is the first word in a user’s message.