I need help with ToUser command

I am trying to set a funny and short command but I need nightbot to answer “a noob” if there is no $(Touser).
i have: $(user) sniped $(touser) from $(customapi http://2g.be/twitch/randomnumber.php?=defstart=1&defend=999)

I want it to answer: (User) sniped a noob from (random number) when the user doesnt mention somebody else.


$(eval a=decodeURIComponent(`$(querystring)`);a=a?a:`a noob`;`$(user) sniped ${a} from ${Math.ceil(Math.random()*999)}`)

@RokettoJanpu thank you so much. You are a legend.

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