Calling Nightbot variable $(user) from Pastebin

Alright, so what my code wants to do is, upon calling, pull a random string from a Pastebin, which by itself works just fine.
However, I also want to call $(user) from within these string values, which I understand is harder than just putting $(user) in the beginning of the command because of how js works.
So, I try to code it to recognize before the random string code, but it keeps giving me an ‘Unexpected identifier’ error.
I’ve looked at past topics here and elsewhere on the topic and applied the advice, but it still doesn’t work.
Does a code like this still work on Nightbot in February 2022?

!thighs $(eval r="$(urlfetch json http://tmi.twitch.tv/group/user/$(channel)/chatters)";eval baby="$(user)";eval a="$(urlfetch json https://pastebin.com/raw/1En8fN5y)".split(";");a[Math.floor(Math.random()*a.length)])

Pastebin is inside the code.

Apologies for the lewdness in advance, it’s kind of the channel brand, lol.

You only need eval after the $( at the beginning the actual js doesn’t read that that’s what make it but whatever is in between the $(eval ) into something to evaluate the code so basically you just don’t need the other evals in their

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.