Transitioning StreamElements codes to Nightbot

Hi all! I’m very new to Twitch and to making custom commands. I’ve been using StreamElements for all my commands, but I’d like to switch over to Nightbot, and I’m having trouble translating commands into Nightbot language.

For example, I’m making a command called !loveletter that’s going to be a bite sized encouraging note to viewers. The code I have for StreamElements is:

$(random.pick ‘:love_letter: eat some food and drink some water :sparkling_heart: i love you’‘:love_letter: one day at a time :leaves: breathe breathe breathe’‘:love_letter: I love seeing you continue even when you dont think you can :sparkles: youve got this’‘:love_letter: wow did you know youre an amazing human? crazy :sparkles: wild even that I get to exist on this planet with you​:sparkling_heart:’)

It works just fine on there, but I’m not sure how to change it for Nightbot. Would someone be able to help?

Thank you! :sparkling_heart: - Sami

Example of how I want it to look when it works correctly:
StreamElements: :love_letter:one day at a time :leaves: breathe breathe breathe
StreamElements: :love_letter:eat some food and drink some water​:sparkling_heart: i love you

etc etc etc

You can use something like this:

$(eval var messages = ['💌 eat some food and drink some water 💖 i love you', '💌 one day at a time 🍃 breathe breathe breathe', '💌 I love seeing you continue even when you dont think you can ✨ youve got this', '💌 wow did you know youre an amazing human? crazy ✨ wild even that I get to exist on this planet with you 💌']; messages[Math.floor(Math.random() * messages.length)])
1 Like

Thank you so much, I tried this and it worked wonderfully!