Nightbot variables in Pastebin

Asked Jun 18, 2021·1 reply·Last activity 5 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.

Hi, i like to put this command in a pastebin link where you can enter many answers.

This is the command : !commands add hi $(eval const a = $(1).toLowerCase(); switch(a) { case "chat?": "Salutations of the day, @$(user). Please allow me so see your honorable panstsu"; break; case "everyone": "Heya, @$(user)"; break; case "guys": "Me too, @$(user)-san?"; break; case "teo": "Why won't you say hi to me, @$(user)? BibleThump"; break; case "reo": "B-BAKA! Don't I deserve a greeting too? What about chat, @$(user)?"; break; default: " ";})

I like to make it something like that :
$(eval a="$(1)";u="$(user)";$(urlfetch json https://pastebin.com/raw/kkGUZ8am))
& in the pastebin i enter something like : case ${a} = "chat" : "Salutations of the day, ${u}. Please allow me so see your honorable panstsu"; ...

The problem is i dont know what to type in the pastebin :frowning_face:
I hope you understand what i'm trying to say, and sorry for my english

1 reply