[DOC] How to Create / Setup a Discord bot with RAT

Trekkan

JFF Administrator
Staff member
Discord roles are hierarchical in nature. Meaning, the role listed in Discord Server Settings at the top, is the most "powerful" above any roles under it. So whatever role you have assigned to your bot, needs to have permissions that #1, allow it to read/write messages, but also if you want to ban a person from Discord through it (as an example), the bot would have to have a role higher than the person the bot is trying to ban.

Also, as a test. Try setting your bots permissions to "Administrator" and see if that works. I think the Discord API might have changed and could be causing some issues as well.
 
Tried giving it Admin access, still didn't work. Does the "username" for the bot have to be somethhing new, or does it have to be an existing Discord username?
 

Trekkan

JFF Administrator
Staff member
Tried giving it Admin access, still didn't work. Does the "username" for the bot have to be somethhing new, or does it have to be an existing Discord username?
Nope, can be anything. I was testing last night and was able to make mine work, so... not sure at the moment.
 
Ok, somehow it just started working, which is nice, but then starting reporting EVERYTHING that was happening in my main discord "general" channel and not my 7D2D channel. Still can't get it to show the sub-channel's in the RAT integration dropdown. Ugh. Any ideas on that one?

Also, is there a way to customize what the bot will report to Discord?
 

Trekkan

JFF Administrator
Staff member
Ok, somehow it just started working, which is nice, but then starting reporting EVERYTHING that was happening in my main discord "general" channel and not my 7D2D channel. Still can't get it to show the sub-channel's in the RAT integration dropdown. Ugh. Any ideas on that one?

Also, is there a way to customize what the bot will report to Discord?
Sounds like in trying ot get it to work, at some point you saved your "general" discord channel in the RAT settings, instead of the one you wanted? I'd try redoing the Discord setup in RAT. You need to hit the "Test" button on the Discord setup in RAT, which then attempts to connect to your server and downloads your channel list. That then populates the channel list so you can tell RAT which channel you want to output to.

As for customization, not much currently. However I'm going to be redoing the RAT Discord code, so there should be a lot of new features and options when I'm done.
 
i setup everything but when i go to test connection nothing happens it stays red on both discord connection and guild connection?
 

Trekkan

JFF Administrator
Staff member
I'd have to look at it on Teamviewer or something, no idea from what I can see right now.
 
we can teamview just let me know when... cause im stumped!! the bot i made is in the discord just offline cause RAT test not working for me
 

Dradonis

New Member
As for customization, not much currently. However I'm going to be redoing the RAT Discord code, so there should be a lot of new features and options when I'm done.
How is this getting along? Main reason is that it would be great to turn off spam messages such as the backup process, server reboot and countdown to reboot messages on a toggle.
 

Trekkan

JFF Administrator
Staff member
How is this getting along? Main reason is that it would be great to turn off spam messages such as the backup process, server reboot and countdown to reboot messages on a toggle.
There hasn't been a lot of work done on this lately as I just haven't had the time.

However, if you just want to edit the messages, you can. Click the Gear icon in RAT (Event Editor), and then just remove the lines you want for the events you want. Or, disable the event entirely if that's what you want.
 

Dradonis

New Member
Literally just discovered you can do it all in the event editor as you replied, big facepalm for me. Yeah all the options are there, just wasn't looking in the right place. My bad!
 
Top