1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.


Send reports from players in-game to a Discord server

Total Downloads: 531 - First Release: Feb 14, 2017 - Last Update: Mar 3, 2017

5/5, 3 likes

  1. Bobakanoosh

    DiscordReport is a plugin that uses the Discord API to allow players to use an in-game command to report a player. It then sends information regarding the report to a given Discord Server.

    If anyone could provide more accurate translations of the lang files, message me please!

    • Send reports from in-game to a discord server, with steam profiles from the reporter and the reported users.
    • Logs reports
    • Lang support for German, Spanish, French, and Russian.
    • Permissions for using the report command
    • Ability to block and unblock a user from using the report command

    /report <user> <reason>
    • The user can be part of a username or a full username, but full username is best. After using this command, it will send a message to your text channel with whatever you gave in your lang file.
    /dr block <user>
    • Blocks a user from using the /dr report command. Useful if someone is abusing the command.
    • Alternatively, you can grant a user the permission for being blocked, found below.
    /dr unblock <user>
    • The opposite of block.
    /dr isblocked <user>
    • Checks if a user is blocked from using /report <user> <reason>
    /dr isimmune <user>
    • Checks if a user is immune from command cooldowns
    /dr ti <user>
    • Toggle a users immunity to command cooldowns through a command, rather than through a permission.

    Default Config:
      "Cooldown between each report (seconds)": 60,
      "Custom chat Prefix: ": "<color=silver>[</color><color=orange>DiscordReport</color><color=silver>]</color> ",
      "Log reports? (true / false)": true,
      "Send steam profile link with reports? (true / false)": true
    discordreport.use - allows you to use the basic /report command
    discordreport.admin - allows you to use /dr block, /dr unblock, and /dr ti <user>
    discordreport.isblocked - blocks the user from using the /report command. This is grantable by an in-game command.
    discordreport.isimmune - sets whether they're immune to command cooldowns
    • Discord.cs
    • DiscordReport.cs
    • Any Discord bot
    • Please note that it's necessary to either host the bot either on your computer or on a server. It takes up hardly any CPU and RAM (maybe 30mb), so anything cheap will do. I'm hosting my own bot on a VM and am allowing anyone to use it, just PM me for the token.
    I've made a very simply Discord bot if you wish to use that. The GitHub for the bot can be found here: GitHub - Bobakanoosh/RustNotifierBot: A bot used for Rust's Oxide mod, integrated with Discord API.

    This contains the .dll's for Discord.Net's library, and the execution file.

    If you already have a bot setup, follow steps 1, 2, 10, 11, and 15.

    1. Put Discord.cs and DiscordReport.cs in your server plugin folder.
    2. Run the server, and then close it. This should generate the DiscordReport.json config file.
    3. Next we'll move on to setting up the bot account. If you don't have a discord account, sign up here, and then login-in.
    4. Next, go to here. This is Discord's developer page. Under the 'My apps' tab, click 'New App'.
    5. Fill in App name, which is basically your bots name. I recommend RustNotifierBot, but any name will work. You can also fill in an app description and insert a bot picture, but both aren't necessary. Here's how I filled it out:[​IMG]Once done, hit 'Create App'
    6. Then, click "Create a Bot User". It will ask if you're sure, say yes.
    7. On the page it brings you to, you'll see a client ID. Insert it into this link:
      . Replace <CLIENT_ID> with yours, without the <>'s.
    8. After going to that page, it will ask if you want to authorize your your both for a server. You must have 'Manage Servers' permission on the server to have the bot join the server.
    9. After having it join the server, make sure it shows up in your server user list. Notice that it's currently offline, lets turn it online!
    10. Going back to the Discord.json, open it with a text-editor like Notepad++. On your Discord Bot's page, you'll see something that says Token: click to reveal. After revealing, you'll get a long string of words. Put this into the Discord.json's "BotToken" area.
    11. To get the "ChannelID", you'll need to enable a setting in discord. In the bottom left, click the settings button. It's a cog. Go to Appearance, and check 'Developer Mode'. This allows you to get User ID's and Channel ID's. Then, right click the text channel (i.e #rust_reports) that you want the bot to send messages to. Click 'Copy ID' and put it into the "ChannelID" field.
    12. You're nearly done! If you chose to download my discord bot, run the RustNotifierBot.exe Application. This will launch a console that will prompt you to enter the Bot token (the long string you used earlier), and the name of the bot. If you mess one of these up, they'll be customizable in the /data/configuration.json file. This is located wherever you ran the program.
    13. Every file that's in the downloaded file is necessary. Do not delete anything.
    14. After all of this, your bot should be online, like any other player! Just to make sure, go ahead and type +bot info. If it replies with information to the bot, then you're good!
    15. The in-game commands listed above should now work.
    Upcoming features:
    • [Done] Command for blocking and unblocking a user from using the report command
    • [Done] Configurable cooldown on commands.
    • [Done] Add immunity to cooldown on commands
    • [Done]Customizable prefix for each chat message.
    If you wish to see anything new, let me know!

    I'm hosting my own on a VM on a box I have. *Note: I'm no longer hosting the bot for people*