Random user and touser variable

Hi, I wanted to know if there is a way to make a !slap command that if used it alone shows a random user, but if someone is tagged show the $(touser)
Sorry if there is something misspelled, I don’t know much English, I hope it is understood. Thanks.

Hey @Corolado!

There already are a couple topics covering this type of command already, please use the search bar before opening a new topic, in the meantime here’s a solution:

!addcom !slap $(eval t='$(touser)'!='$(user)'?'$(touser)':'$(urlfetch https://2g.be/twitch/randomviewer.php?channel=$(channel))'; '$(user) slaps '+t)
2 Likes

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