• ServerBase - A simple but effective server tools addon
    23 replies, posted
[b]What is ServerBase[/b] ServerBase is a lightweight server 'administration/tools' addon that allows server owners and/or administrators to manage their players with ease. It's a small project that I am working on when I have the spare time and I have been working on it slowly over the past few months. [b]Features:[/b] - Administration System that allows timed mutes and voicemutes as well as bans. - RTD feature that is easy to edit and add to for those who know basic lua - Server Portal that allows you to add your servers if you have multiple servers. - Suspensions Management System that allows you to add, remove and modify suspensions whilst players are/aren't on the server. - Simple style to give something other to look at other than the basic derma. - Logging System that logs events on the server such as players chatting, admin commands and death notices. - Simple Rules menu that allows you to add your own rules to the server. - Very basic commands system that gives you easier access to things like the menus of the features/systems. [b]Administration System[/b] [thumb]http://puu.sh/668s0.png[/thumb] This is the admin menu, it allows you to do the following to players with ease: - Kick - Ban - Slay - Mute - Voicemute - Bring them to you - Teleport to them It also has a button that leads to the suspensions management system so there is no need to exit the current menu to open the suspensions menu. [b]RTD Feature[/b] [thumb]http://puu.sh/668GI.png[/thumb] To use this feature all you have to do is type /rtd, it will then make sure that you haven't rolled in the past 2 minutes (or whatever you set the time to in sh_config.lua) to prevent spam and then choose a random outcome for the player out of the existing outcomes. Each outcome either is a positive outcome or a negative outcome apart from one which is the "nothing" outcome. Cooldown: [thumb]http://puu.sh/668Sl.png[/thumb] It will also display a message similar to this if you are dead such as "You can not roll the dice when you are dead". People who know basic lua will be able to add their own outcomes if they wish. [b]Server Portal[/b] [thumb]http://puu.sh/6692c.png[/thumb] Although very simplistic it will allow you to add your own servers in sh_config.lua with descriptions for the tooltip on hover and the names/IPs of those servers. [b]Suspensions Management System[/b] [thumb]http://puu.sh/669aE.png[/thumb] This is the suspension management system that allows you to modify, add or remove current suspensions on the server/servers. You can add suspensions by simply typing in the relevant information into the text fields and then hitting the "Add Suspension" button. You can also remove suspensions by clicking on the line and pressing the "Remove Suspension" button. You can edit the suspensions as well by clicking on the line and pressing on "Edit Suspension". [b]Logging System[/b] [thumb]http://puu.sh/669Cj.png[/thumb] The logging system creates a new log every map change or server restart; it does this so that there isn't one big files full of text no one wants to go through. It also makes it easier as it has smaller file sizes which make the files easier to read and view. [thumb]http://puu.sh/669HT.png[/thumb] At the moment the system only logs deaths, player spawning and admin commands but more can be added if requested. [b]Rules Feature[/b] [thumb]http://puu.sh/669Sh.png[/thumb] Just a very basic feature that reads from the rules table that you can customize in sh_config.lua; although try to keep the rules to a minimum because as you can see it won't show an endless list; I'll come up with a way to make it better using lists or something. [b]Chat Commands System[/b] Chat commands system has been reworked and is using a better system than the basic playersay system: - /ban <userid> <minutesor0forperma> <reason> - /kick <userid> <reason> - /slay <userid> - /mute <userid> <minutes> <reason> - /voicemute <userid> <minutes> <reason> - /goto <userid> - /bring <userid> - @ - admin chat. - @@ announcement. - @@@ on-screen instruction [b]Planned Features:[/b] - Votemap system with ease of customization for gamemodes. - Requests if they're reasonable to me. [b]Links + Download[/b] You can download the latest version of ServerBase here: [url=https://github.com/Doubleedge/serverbase/archive/master.zip]Link[/url] You can also submit any bugs you find either here or: [url=https://github.com/Doubleedge/serverbase/issues]Link[/url] [b]Credits[/b] - Shendow - Helped me solve a few bugs along the way. - NECROSSIN - Also helped me solve a few bugs along the way. - Wishbone - Has made quite a few contributions that has improved the code.
Can I suggest using [lua]chat.AddText[/lua] for the chat notifications? You can set colors and make it stand out a whole lot more.
I'll add that to my todo list, thanks for the suggestion.
Looks great, however I have to say try a different colour scheme, I.e blue and a slightly lighter blue. Just try to make the colours contrast slightly more, it's more aesthetically pleasing
I was thinking about adding in some sort of configuration that would allow users to create their own colour schemes; like use variables and stuff for easy customization and personalization.
[B][U][I]Looked good, but I can't figure out how to make myself admin. There is no documentation on this, and I can't find the command. Please help![/I][/U][/B]
You have to make yourself admin by going into your server's settings/users.txt and putting your steam ID in there. I'll try to add an easier way to make users admin.
If you're going to chat text you should add a feature that allows people to toggle them on and off, or hide them based on group permissions.
[i]I know it's been a while but I've been busy with coursework.[/i] [b]Update[/b] + Made use of the chat.AddText() for coloring messages, credits to wishbone for merging the function into SB and Overv for the serverside chat.AddText(). + Added a proper chat command system, again credits to wishbone for assistance on that. + Changed the color scheme to a slightly lighter blue rather than a green. + You can now use chat commands such as: goto, slay, ban, kick, voicemute, mute and bring; the arguments for the commands work in chat as well. To make use of commands such as ban you'll need to get the userid of the player by typing in status in console. I can't say I'll be actively working on this but I'll still be doing the odd few things here and there. Again for those that care, sorry for the delay.
[b]Biggish Update[/b] + Changed the color scheme a bit; I'm not exactly a great designer so please suggest something if you don't like it. + Added a votemap system; at the moment you only get one vote; I'm planning on making it depend on your kills; if there are no kills then it would just default as one vote. + Made it so players can't vote more than once; once you vote for a map you can't vote for another. + Added the function GetWinningMap() which you can call in your gamemodes to get the winning map; if there is none it'll pick one at random. + Fixed a few bugs such as typing errors and whatnot. + Added accounts to ServerBase; you now get an account; accounts currently hold coins and VIP status which have no value right now; I plan on doing stuff with this later on. + Added functions such as AddMoney, GetMoney and TakeMoney. + Currently the accounts save at an interval of 1 minute; saving when a player disconnects/leaves will be added. [b]Screens[/b] [b]Accounts[/b] [thumb]http://puu.sh/9w48g/96913357bf.png[/thumb] [thumb]http://puu.sh/9w4Iz/fec5349c8b.png[/thumb] [thumb]http://puu.sh/9w4Ag/ae86a7d449.png[/thumb] [thumb]http://puu.sh/9w4Co/01b1b3f356.png[/thumb] [b]Votemap[/b] It's very basic at the minute; I'll add more things to it on request. [thumb]http://puu.sh/9w4FR/42ba4e4469.png[/thumb] [thumb]http://puu.sh/9w4Iz/fec5349c8b.png[/thumb] I've started working on this again and feel like I should post some more content; everything you see here is on the current GitHub so feel free to download and report any bugs.
Would you consider adding a warning system? I have one I could give you as an example if you wanted it
Could you elaborate more on this warning system? Like some sort of system that stores warnings on the users account for reference or a warning system where an admin can visually warn them like a pop up or something?
For love of god please don't save ip addresses in the data folder
[QUOTE=john552;45156593]For love of god please don't save ip addresses in the data folder[/QUOTE] Why not?
People can use a DLL and download the .txt and get players IP and ddos them?
[QUOTE=BigBadWilly;45158622]People can use a DLL and download the .txt and get players IP and ddos them?[/QUOTE] That doesn't even deserve a comment, however, allow me to make one anyways! The downloading files has been patched (for the most part). IP address is nothing secret and confidential. It is publicly disclosed within everything you do (Every server you connect to etc)
(Every server you connect to etc): Ya, But not to the general public. Secondly: Yes I do know there is a script you can use to grab IPS still like in Gmod 12 but it's hard as fuck, It's only been patched PARTLY, Meaning it can still be exploited.
[QUOTE=BigBadWilly;45159808](Every server you connect to etc): Ya, But not to the general public. Secondly: Yes I do know there is a script you can use to grab IPS still like in Gmod 12 but it's hard as fuck, It's only been patched PARTLY, Meaning it can still be exploited.[/QUOTE] Not really, anybody who can make an instance of the PlayerConnected hook can access it (whether it be by the server owner having sv_allowcslua on or other methods, such as a CSLua bypass). And by general public, really anybody who's ever played any source game has their IP listed somewhere, whether it be by logs or one of those games stats pages.
[QUOTE=Freezebug;45160210]Not really, anybody who can make an instance of the PlayerConnected hook can access it (whether it be by the server owner having sv_allowcslua on or other methods, such as a CSLua bypass). And by general public, really anybody who's ever played any source game has their IP listed somewhere, whether it be by logs or one of those games stats pages.[/QUOTE] Wrong, wrong wrong wrong. the DownloadFile exploit was only fixed for downloading /cfg files as being able to DL the /data folder has always been a thing. Player_Connect from game events no longer lists the IP on connect, is not possible from the client's perspective. using the net channel to dl /data is still possible and also public.
Freeze: Why do you think ULX stopped putting IPS in there log files? Because people downloaded the today logs and check when the player joined saw there IP and did what they wanted.
I don't even log the player IP addresses so it's fine; this addon is meant for servers so people should only be using it on the server; plus if you use it on the client it uses localhost as the file name.
We were talking about servers the whole time and saying that if it did log Ips that it could be exploited to ddos people? If am right someone said the addon did Log ips?
The only IP that is logged is the server IP which is already public. The only things I log currently are admin commands, player connections with their SteamIDs and player deaths; I have no intention of logging client IP addresses at this time and I certainly wouldn't show the full IP if I did log them. [lua] hook.Add("PlayerSay", "PlayerChatLog", function(ply, text, public) SBLOG("[Player Chat] - " ..ply:Nick()..": " ..text) end) hook.Add("PlayerInitialSpawn", "LogPlayerSpawning", function(ply) SBLOG("[PLAYER SPAWNED] - " ..ply:Nick().. "(" ..ply:SteamID()..")") end) hook.Add("PlayerDeath", "LogDeath", function(v, w, k) if ( v == k ) or ( !k:IsPlayer() ) then SBLOG("[DEATH LOG] - " ..v:Nick().. " KILLED THEMSELVES") return end SBLOG("[DEATH LOG] - " ..v:Nick().. "was KILLED by " ..k:Nick().. " using " ..w:GetClass()) end) [/lua] - Example Snippet.
bump - good addon imo, constantly updating
Sorry, you need to Log In to post a reply to this thread.