is there a way to have a command only work whenever a certain game is set on your stream like if i have lol active the command works but if i have another game set the command does not work
Cykotiq wrote an API that fetches a Twitch channel’s game.
$(urlfetch https://twitch.api.scorpstuff.com/game.php?user=$(channel))
You can use this along with some $(eval) logic to output a response only if your game is set, for example, to League of Legends.
$(eval `$(urlfetch https://twitch.api.scorpstuff.com/game.php?user=$(channel))`==`League of Legends`?`some response here...`:` `)
Or, if you want to use what Nightbot has to offer rather than an API that does the same job, you can use: $(twitch $(channel) "{{game}}")
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.