[Question] Can you limit access to one Twitch channel with mIRC? reddit / irc ---------------------------------------------------------------------- AWarmShower · 2016-08-08 22:49 My friend made a bot, and we plan to distribute it among members of a close community. However, we're worried that some may use it for malicious purposes. The bot is installed and can be used to join any channel you wish. We hope most users will only join their channel, but we understand humans are humans and may let their emotions get the best of them. The question is: Can we make mIRC only be able to join one channel, so that it cannot be used maliciously on other channels? Can we make it so that mIRC blocks the fields (and buttons) that allow you to manually join a channel and add channels? Can we add passwords to channels?   Any help is appreciated! Thanks! ---------------------------------------------------------------------- jumpking · 2016-08-08 22:55 There are a variety of different ways to accomplish some of what you want, but all of them can be easily removed or undone by the person who has the bot. ---------------------------------------------------------------------- AWarmShower · 2016-08-08 22:58 What's the most complicated way to do it that would be somewhat hard for a simple streamer to undo it? ---------------------------------------------------------------------- jumpking · 2016-08-08 23:06 I'm not really going to delve into all of it, but here's a super quick example... Bury this somewhere in one of your scripts in the Remotes tab: on *:join:*: { var %allowedchannels = #mychannel123 #anotherallowedchannelhere if (($nick == $me) && ($chan !isin %allowedchannels)) { !part $chan } } This may conflict with any other ON JOIN events in the same file. This really isn't a solution, though. It's just a band-aid. The people you give your bot to should be trustable or you should look into making a bot in another language that doesn't have this sort of problem. ---------------------------------------------------------------------- AWarmShower · 2016-08-08 23:11 This makes sense! Thank you so much! ---------------------------------------------------------------------- jumpking · 2016-08-08 23:13 No problem :) ---------------------------------------------------------------------- Zigress · 2016-08-09 21:12 I tried this out, and it worked pretty well. I even added "echo" in there to say "you cannot join this channel." However, I would like to know... How do I get around it LOL? Asking because I do not know how to reverse it now. Taking this out of the code doesn't fix the problem. ---------------------------------------------------------------------- Zigress · 2016-08-09 21:30 Also, this is basically a whitelist, right? People can only join the listed channels. How would I go about making a blacklist, where people can join all channels except the ones listed? ---------------------------------------------------------------------- jumpking · 2016-08-09 23:06 For your first question in your other comment: Removing the code and hitting OK in the Scripts Editor is enough to stop the code from working. To make it a blacklist, on the 3rd line you'll see *!isin*, simply remove the exclamation mark to make it read *isin* and it should function the way you want it. The original code basically works like this: if (($nick == $me) && ($chan !isin %allowedchannels)) { "If I joined (**if $nick == $me**) a channel and (**&&**) the channel I joined (**$chan**) is not in (**!isin**) the variable (**%allowedchannels**) then issue the part command." Further clarification: **$nick** is filled with the nickname of the person who triggered the ON JOIN event, and the **$me** identifier is filled with your current nickname. **$chan** is filled with the channel that the ON JOIN event was triggered in. and **%allowedchannels** contains a list of channel names. **isin** by it self checks to see if is contained anywhere within . In this case, it checks to see if the channel that triggered the ON JOIN event is listed anywhere inside of the variable **%allowedchannels**. The exclamation mark in front of **isin** in the original code changes it so it becomes the opposite meaning. So, instead of "if thing is in otherthing", it becomes "if thing is **not** in otherthing" I hope thats a decent explanation of how it all works. Feel free to reply back if you still have more questions, etc. ---------------------------------------------------------------------- Zigress · 2016-08-09 23:30 Wow, thank you for the very elaborate reply. This helps a lot. :)