mIRC Homepage
Posted By: vip3r22 Randomize commands - 20/03/15 07:25 PM
I've been searching for this but haven't had any luck, if someone can point me in the right direction or let me know if this is even possible:
I have a Twitch bot that I would like to have set up to where it selects a random command that viewers will try to guess. They will be given hints as to what the command is. My problem is 'activating' a new random command every time one is correctly guessed and also assigning the correct clues/hints to each command. Thanks for any insight on this. DISCLAIMER: I'm still pretty new to this stuff, but I generally learn pretty quickly.
Posted By: Nillen Re: Randomize commands - 20/03/15 09:17 PM
You should probably learn to use ini files for something like this

I imagine that you could build an ini file like so:

[Command1]
Hint1=Hint 1 Text
Hint2=Hint 2 Text

[Command2]
Hint1=Hint 1 Text

etc.

Then just random between the content of the file's sections using $ini.

/help $ini
/help $readini
/help $rand

You can build a command using these things
Posted By: vip3r22 Re: Randomize commands - 22/03/15 05:25 PM
But is it possible to set it up so that only 1 command will respond at a time? For example, if command 1 is !apples and command 2 is !cherry, they would have similar hints so I wouldn't want command 2 to respond if that was someone's guess. Thanks for the response.
Posted By: Nillen Re: Randomize commands - 22/03/15 05:33 PM
Of course it is, you can script pretty much whatever it is you want, especially if it's text based responses.

You can set up however many if statements in your scripts as you please.
Posted By: vip3r22 Re: Randomize commands - 22/03/15 05:45 PM
Okay nice! Thanks for the help, I wanted to be sure this could be done before I dug into it more.
© mIRC Discussion Forums