SysReport - Report With Ease!

Addon: SysReport
Version: 1.2


SysReport is a easy to use Reporting System…

Just fill in the catagories that best describes the troublesome player and click “Report!”
This will then be sent to the “Review Tab” that only admins have access to.
Here admins can review old or recent reports of players.
Only SuperAdmins have the permission to clear the Reports.
If you don’t prefer the DTextEntry panel to review the Reports, then you can just click the “Print” button to print all the Reports into console!


How To Install

Just place the SysReport folder into the Server’s addon folder. Then simply restart the server and you will be good to go.

How To Use

To Report a player either type “!rmenu” in chat or “sys_reportmenu” in console.

Report Bugs or Suggestions

If you have any bugs to report or suggestions, please post them in this thread!

Where Can I Get This?


That’s awesome! :smiley: I’m adding this to my server now!

An excellent addon! Looks like we have another good Lua coder coming into the community.

I do have one recommendation though: I would make your anti-spam check dependent on the server rather than the client. In theory, I could simply do

AntiSpam = 0;

Which would spam spam spam.


Add a “Custom” reason option, and this will be golden.

-Version Update-
Old Version: 1.1
Current Version: 1.2

-Version: 1.1 Updates-

The Report Tab has been redone.
Derma Controls have been shifted around for a better placement.
Added a “Custom Reason” entry that allows you to enter a custom reason.
Transfered the AntiSpam function over to ServerSide.
Fixed some bugs involving:
Not being able to close the Report Menu.
Clients getting invalid panel errors.

-Version: 1.2 Updates-

Fixed some issues with non-admins getting the “Admin Usage Only!” message everytime they open the menu which can get annoying…

Deleted some useless things within the code.

This could be easier for admins to act on if the report is more chat based (racism through chatbox, etc), that a log is saved into the report from up to two minutes ago.
Also, for a custom report, a Chatbox logs feature could make customized reports have this ability too if needed.

Just my opinion.

Nice idea. I wrote something like this a while back, didn’t think it was worth releasing though, but the feedback here proves me wrong.

Well this looks like a rip from ReportX

Just because someone else made something similar and your addon is more efficient doesn’t mean you can’t share it with everyone else.

It’s funny how it’s exactly the same code as reportx.

Um… What to you mean “exactly the same code as reportx”, to be honest with you I didn’t copy any code from this other reporting addon. And how is it “exactly the same code”, I just downloaded it one moment ago and compared my reporting system between theirs. They are not the same. Sure, they both follow the same guidelines of logging. Besides that, it’s not exactly the same code.

It’s funny how every time there’s a release on Facepunch someone comes along and says “This is entirely stolen from <similar addon here>”

Or “Theres something else like it, this isn’t unique at all”.

It happens too much I’m afraid.

Nice work man! Do you remember me? Turdleman and I run the MG server. I never knew that you knew how to code. I haven’t seen you in forever.

Fisheater definitely did not copy code… This is different. I compared the code myself - It is different.

Below is the code from SysReport, and below it is code from ReportX.

//SysReport ServerSide


local ReportedUser = {}
local AntiSpam = {}

if !file.Exists( "sys_reports.txt" ) then file.Write( "sys_reports.txt", "" ) end

hook.Add( "PlayerSay", "FindReportMenuAccess", function( ply, text )
if string.lower( string.sub( text, 1, 11 ) ) == "!rmenu"  then    
ply:ConCommand( "sys_reportmenu" )
end )

concommand.Add( "sys_report", function( ply, cmd, args )

if string.len( args[2] ) > 3 then

if AntiSpam[ply] then --Return the function...
    ply:ChatPrint( "Sorry, but you can only report once every two minutes." )

for k, v in pairs( player.GetAll() ) do
    if string.lower( v:Nick() ) == string.lower( args[1] ) then
        table.insert( ReportedUser, v )
for k, v in pairs( ReportedUser ) do
            if args[1] ~= "" and args[2] ~= "" and args[3] ~= "" then
                filex.Append( "sys_reports.txt", "Report Sent In On: " .. .. "
" )
                filex.Append( "sys_reports.txt", "Player: " .. ply:Nick() .. " (" .. ply:SteamID() .. ") 
" )
                filex.Append( "sys_reports.txt", "Reported: " .. v:Nick() .. " (" .. v:SteamID() .. ") 
" )
                filex.Append( "sys_reports.txt", "Reason: " .. args[2] .. "
" )
                filex.Append( "sys_reports.txt", "Level: " .. args[3] .. "
" )
for k, v in pairs( ReportedUser ) do
    table.remove( ReportedUser, k )

AntiSpam[ply] = true

timer.Simple( 120, function() AntiSpam[ply] = false end )
end )

concommand.Add( "sys_receivereports", function( ply )
if ply:IsAdmin() then
datastream.StreamToClients( ply, "sysreports", string.Explode( "
", file.Read( "sys_reports.txt" ) ) )
end )

concommand.Add( "sys_cleanreports", function( ply )
if ply:IsSuperAdmin() then
file.Delete( "sys_reports.txt" )
file.Write( "sys_reports.txt", "" )
end )




if !file.Exists("reports.txt") then file.Write("reports.txt","") end

concommand.Add( "report_user", function( ply, cmd, args )
    for k,v in pairs( args ) do
        args[k] = string.gsub( v, "'", "" )
    local Players = {}
    local Reporter = ply
    if(!ValidEntity(Reporter)) then return end
    if(!args[2]) then     
        Reporter:ChatPrint("Please specify a player and a reason to report them.")
    local Reported = args[1]
    local Reason = table.Copy( args )
    table.remove( Reason, 1 )
    Reason = table.concat( Reason, " " )
    for k, v in pairs( player.GetAll() ) do
        if string.find( string.lower( v:Nick() ), string.lower( Reported ) ) then
            table.insert( Players, v )
    if #Players <= 0 then
        Reporter:ChatPrint("Sorry, no players were found!")
    if #Players > 1 then
        Reporter:ChatPrint("Sorry, multiple players were found!")
    Reported = Players[1]
    local Text = "Report made on " .. .. " :\
    Reporter: " .. Reporter:Nick() .. " (" .. Reporter:SteamID() .. ") \
    Reported Player: " .. Reported:Nick() .. " (" .. Reported:SteamID() .. ") \
    Reason: " .. Reason .. "

    filex.Append("reports.txt", string.gsub( Text, "    ","") )
    Reporter:ChatPrint("You have reported " .. Reported:Nick() .. " (" .. Reason .. ")")
end )

concommand.Add("report_getreports", function( ply )
    if ply:IsAdmin() then
        local f = string.Explode( "
", file.Read("reports.txt") )
        datastream.StreamToClients( ply, "reports", f )
        ply:ChatPrint("Sorry, this is admin only!")
end )

hook.Add( "PlayerSay", "Report_User", function( ply, text )
    if string.lower( string.sub( text, 1, 7 ) ) == "!report" or string.lower( string.sub( text, 1, 7 ) ) == "/report" then    
        return ""
end )

People just either ignore my addons or flame them. :saddowns:


The only thing your going to succeed by editing other users work ( As well as not giving them credit ) is becoming a major adversary to this forum and getting spammed with dumb ratings.

From those code snippets, I’d say this was made from scratch. There are some similar parts, yes, but that’s expected for 2 addons that do the same thing.

Anyway, I don’t like the gui very much. You need to revise your spacing and general layout of controls. For example, on the first picture, why is there a DFrame inside a tabbed panel? Make the tabbed panel parented to the DFrame, with 5 pixels of padding each way, and remove the “Close” button in favour of the cross provided by the DFrame.

Then you got that massive space for a drop down box and a button, which opens another window. Have a list box (DMultiChoice I think) with all the players going down the left side, taking up 100% of the height of the space provided by the tabbed panel (maybe with 5 pixels of padding both ways) and about 1/3 of the width. Then have your reason textbox and stuff occupying the rest of the space, with the “Report” button at the bottom. Make sure there is at least 5 pixels between any border.

The view tab is better, but shift all the buttons to the bottom (again, remove the “Close” button) and line them up like a toolbar, and make the preview box take up the rest of the space (again, obeying the 5 pixel rule for padding). You can remove the title labels too, since it’s already obvious what the tab does based on the text of the tab and the content of the panel.


Also I was going to rage about “Print” being useless when I realised it prints to console, not the printer. :v:

I wish it printed to my printer :smiley:
JOHNSON! I want a list of anyone minging on our server STAT!
Yes sir just let me print the reports

Uhm yea the acting probably sounded a lot better in my head but anyways nice updates from 1.0 to 1.2 Fisheater, great job on this addon ive already seen it on a few servers :smiley:

Anyways nice ideas to improve it thomas i cant wait to see if it gets updated again… a new look would make this a stupendous addon! (if it isnt already!)