After the update, when a player is banned and tries to connect they get kicked out like they normally would. But on the website it is not updating the "Latest Players Blocked" section.
Just thought I'd like to point that out, so hopefully it gets fixed.
im on vacation atm. but i will take a look when i get home.
I think the blocked player list not updating is the same problem that effected ulx showing the kicked/banned player as console. Moving SBAN.Player_AddBlock above SBAN.Kick should fix the problem.
Edit: Also the only string that you escaped is the name, you really should escape the reason as well since any admin with basic MySqL knowledge could some bad things with that...
also can you make it so you can tyoe a ulx command in chat to unban someone from sourcebans. This would be amazing
Is it possible to get this to link with the voteban functionality in ULX? I'd tried it myself, but I can't seem to get it to work.
I'd really like it if someone's banned by !voteban that it adds it to SourceBans banlist instead of the ULX banlist, maybe saying the admin is CONSOLE along with the reason they got votebanned + ban length.
If anyone knows how I can do this, please let me know.
I'm stuck!
[ERROR] addons/ulx/lua/ulx/modules/sban.lua:124: attempt to index global 'SBAN_MYSQL' (a nil value)
1. Player_CheckBanned - addons/ulx/lua/ulx/modules/sban.lua:124
2. fn - addons/ulx/lua/ulx/modules/sban.lua:190
3. unknown - addons/ulib/lua/ulib/shared/hook.lua:183
4. UniqueID - [C]:-1
5. query - addons/ulib/lua/ulib/shared/sh_ucl.lua:48
6. echoToAdmins - addons/ulx/lua/ulx/log.lua:164
7. fn - addons/ulx/lua/ulx/log.lua:205
8. unknown - addons/ulib/lua/ulib/shared/hook.lua:183
I saw another guy earlier was getting this error but he said it fixed itself. Mine isn't fixing itself. Does anyone have any suggestions? Thanks!
[QUOTE=Phar;45415611]Is it possible to get this to link with the voteban functionality in ULX? I'd tried it myself, but I can't seem to get it to work.
I'd really like it if someone's banned by !voteban that it adds it to SourceBans banlist instead of the ULX banlist, maybe saying the admin is CONSOLE along with the reason they got votebanned + ban length.
If anyone knows how I can do this, please let me know.[/QUOTE]
Extremly easy to do. Simply go to this file in the ulx addon, ulx/ lua / ulx / modules / sh / vote.lua
Find line 303 replace this:
[lua]ULib.ban( target, time, reason, ply )[/lua]
With this
[lua]SBAN.Player_Ban( target, time, reason, ply:SteamID() )[/lua]
That will make it so voteban bans via sbans. :)
I am wondering if the error I posted is due to the fact that I got this message with the install of Sourcebans:
The final step is to add this to your databases.cfg on your gameserver (/[MOD]/addons/sourcemod/configs/databases.cfg)
This code must be added INSIDE the `"Databases" { [insert here] }` part of the file.
"driver_default" "mysql"
"sourcebans"
{
"driver" "default"
"host" "localhost"
"database" "db name"
"user" "db user name"
"pass" "db password"
//"timeout" "0"
"port" "3306"
}
Finish Up
The setup of SourceBans is finished. Delete this folder to complete the install.
The problem is I cant figure out where to put this code, since I dont have sourcemods and dont have a databases.cfg on my server. I created the cfg file and put it in my config directory but that didnt work. The db is running correctly with sourcebans on it, I just cant use this addon.
Has anyone else had this problem or gotten this?
[QUOTE=TheEmp;45417699]Extremly easy to do. Simply go to this file in the ulx addon, ulx/ lua / ulx / modules / sh / vote.lua
Find line 303 replace this:
[lua]ULib.ban( target, time, reason, ply )[/lua]
With this
[lua]SBAN.Player_Ban( target, time, reason, ply:SteamID() )[/lua]
That will make it so voteban bans via sbans. :)[/QUOTE]
That is something I attempted to do earlier. Only difference is I did this:
[lua]SBAN.Player_Ban( target, time*60, reason, ply:SteamID() )[/lua]
because 1440 for ulx is 1440 minutes, and 1440 for sban is 1440 seconds.
HOWEVER, While it does work if an admin starts the voteban, if a non-admin (someone not registered on the sourcebans database) does the voteban, it only kicks the client and doesn't add their entry to the ban list. Probably because they're not considered "admins", which is why I wondered if there was a way to force them as "CONSOLE" in the sourcebans database.
This is what I got in my server log after we tested it, and it didn't exactly have any "useful" hints:
[CODE]L 07/17/2014 - 13:25:55: [ULX] xxpysch_killer started a voteban of 1440 minute(s) against [DA] Bloodprince
L 07/17/2014 - 13:26:02: "minecraftjude<150><STEAM_0:1:88239716><>" disconnected (reason "Disconnect by user.")
L 07/17/2014 - 13:26:16: [ULX] xxpysch_killer approved the voteban against [DA] Bloodprince (1440 minutes) ()
L 07/17/2014 - 13:26:16: "[DA] Bloodprince<175><STEAM_0:1:41203511><>" disconnected (reason "You have been banned for this server (), please visit bans.darkenedalliance.com")
L 07/17/2014 - 13:26:19: "xxpysch_killer<144><STEAM_0:1:69853864><Team>" say "its worked"
L 07/17/2014 - 13:26:56: "xxpysch_killer<144><STEAM_0:1:69853864><Team>" say "lel"
L 07/17/2014 - 13:27:00: "[DA] Bloodprince<178><STEAM_0:1:41203511><>" connected, address "75.159.71.145:27005"
L 07/17/2014 - 13:27:00: "[DA] Bloodprince<178><STEAM_0:1:41203511><>" STEAM USERID validated
L 07/17/2014 - 13:27:09: "[DA] Bloodprince<178><STEAM_0:1:41203511><>" entered the game[/CODE]
So here's basically the question I'm asking: Is there a way to set it up that if a non-admin starts a voteban and it succeeds to consider the admin as CONSOLE and enter the entry? Because it's hardly useful if admins, who can just use sban/sbanid, can only use voteban. :P
Ah alright, I'll take a more in depth look at it whe I get home in an hour. There is most certainly a way to get it to work. The first way that comes to mind is to use [URL="http://wiki.garrysmod.com/page/Global/RunConsoleCommand"]RunConsoleCommand[/URL] to run ulx sban, how ever if I remember correctly this script does not support using the console to ban players. Seeing as the query to see if a player has admin uses steamids and consoles dont have those. :P
[QUOTE=Duinrahaic;44799891]I have managed to install this module onto one of my servers (a TTT server) but I am not able to install it correctly without getting a lua error when I process a command on my other server (a prop hunt).
I get this lua error when I try to use the sban command:
Can someone help me figure this out?
Edit: It fixed itself.[/QUOTE]
This is the error we were both getting:
[ERROR] addons/ulx/lua/ulx/modules/sban.lua:124: attempt to index global 'SBAN_MYSQL' (a nil value)
1. Player_CheckBanned - addons/ulx/lua/ulx/modules/sban.lua:124
2. fn - addons/ulx/lua/ulx/modules/sban.lua:190
3. unknown - addons/ulib/lua/ulib/shared/hook.lua:183
4. UniqueID - [C]:-1
5. query - addons/ulib/lua/ulib/shared/sh_ucl.lua:48
6. echoToAdmins - addons/ulx/lua/ulx/log.lua:164
7. fn - addons/ulx/lua/ulx/log.lua:205
8. unknown - addons/ulib/lua/ulib/shared/hook.lua:183
Duinrahaic, do you have any idea how it fixed itself? I would love to use this module but I am absolutely stuck! I have rechecked everything. Mysqloo, sourcebans, this module are all installed correctly but I can't get past this one single error. I have searched the web for possible answers. Any suggestions at all will be soooo appreciated!
I recently got an Anti-Cheat and I want it to be able to ban people via this Source Bans module.
Sadly, I can't because this does not allow bans via console or with an admin ID of 0 (which is also console).
Please do consider adding this feature!
It effects my ULX group vip. We have auto donate system, so how do I go about this, I don't want source bans to affect certain groups.
F14, put something like this
if ply:IsUserGroup( "mod" ) then don't reset else reset end
somewhere near the SBAN.Admin_Reset function.
[QUOTE=F14;45526572]It effects my ULX group vip. We have auto donate system, so how do I go about this, I don't want source bans to affect certain groups.[/QUOTE]
I just commented out the code that adds the groups from sourcebans, If you want the code let me know
Am i the only with this problem?
[URL="https://www.dropbox.com/s/fqfcpbvbm3zl7op/e368417dbcef491c36ebdfdbc1c26510.png"]Dropbox png[/URL]
I don't know if its related to this module or if it is mysqloo breaking on me
[QUOTE=kngrektor;45560932]Am i the only with this problem?
[URL="https://www.dropbox.com/s/fqfcpbvbm3zl7op/e368417dbcef491c36ebdfdbc1c26510.png"]Dropbox png[/URL]
I don't know if its related to this module or if it is mysqloo breaking on me[/QUOTE]
you need to install mysqloo
[QUOTE=FunDK;45560968]you need to install mysqloo[/QUOTE]
I'l go to the mysqloo thread then, since it should be installed
I had issues some Hours.. installing it but.. after some script changing.. on the sban.lua and on the sban_mysql.lua... I made it to work fine... :)
-
if you have Issues.. wiht the Mysql lossing connection Open sban_mysql.lua and go to line 44 and replace the line wiht:
[code]LINE:44 sban_db = mysqloo.connect(SBANDATABASE_HOSTNAME, SBANDATABASE_USERNAME, SBANDATABASE_PASSWORD, SBANDATABASE_DATABASE, SBANDATABASE_HOSTPORT)[/code]
Can you or somebody else consider making this more efficient. When this is not installed, the var on my server is below 1. When it is installed, the var slowly jumps from 10 to 25 and causes CPU lag spikes which result in a very small FPS/tickrate drop every few seconds.
Here is the server WITH this module installed:
[url]http://compactgamers.com/storage/videos/8-5-2014_sourcebans-tick-drops_with.mp4[/url]
And here is the server WITHOUT the module installed:
[url]http://compactgamers.com/storage/videos/8-5-2014_sourcebans-tick-drops_without.mp4[/url]
This is a default install server, nothing installed but ULX with this module.
Here are one of my servers at around 15 players with constant tickrate drops and spikes on the graph:
[url]http://compactgamers.com/storage/videos/8-5-2014_sourcebans-tick-drops_withserver.mp4[/url]
When one of my servers reach around 30-40 players, these mini lag spikes become way too noticeable and the tickrate is dropping even faster. The MySQL database is hosted in the west coast, and the servers are hosted in the east coast. This is the only SourceBans module I use because it does what its supposed to do, but this problem is not good. Please do look into this! Or somebody else!
EDIT: Why is there a watchdog that is constantly watching the database every 1 second? I increased the value from 1 to 10 and these var increases happen every 10 seconds now, but last for less than a second and fixed the problem.
I'm currently running utime with auto-promote and i have it so after 30 hours people get promoted automatically to Regular, but because of SourceBans it doesnt promote them they get demoted by source ban and utime tries to promote them again, so it goes back and forth. So i want to know if there is a way to exclude certain ulx groups from being touched by sourcebans?
Error: Acces denied for user "HERES MY USERNAME"@'185a49b14c178.greendata.pl (USING PASSWORD: NO)
I`m 100% sure that password is correct. Should i have separate databases for sban in game and in web?
[QUOTE=xSkyer;45627987]Error: Acces denied for user "HERES MY USERNAME"@'185a49b14c178.greendata.pl (USING PASSWORD: NO)
I`m 100% sure that password is correct. Should i have separate databases for sban in game and in web?[/QUOTE]
put 185a49b14c178.greendata.pl in Remote Database Access Hosts (Remote MySQL)
[QUOTE=nissedude;45638450]put 185a49b14c178.greendata.pl in Remote Database Access Hosts (Remote MySQL)[/QUOTE]
It worked!
How to replace ulx ban with sourceban?
i have a problem. i didnt get the rights from the webinterface i want to give me the full rights an i dont get the group
[QUOTE=npd1124;45549012]I just commented out the code that adds the groups from sourcebans, If you want the code let me know[/QUOTE]
I would love the code, whats your steam?
Any word on an importer for existing ulx bans? I tried myself, but it failed. Here's the failed code if it's useful:
[lua]
local function ZerfBans()
if not SERVER then return end
local bandata = ULib.parseKeyValues(file.Read("ulib/bans.txt", "DATA"))
for key, value in pairs(bandata) do
local curban = bandata[key]
sourcebans.BanPlayerBySteamID(key, curban.unban, curban.reason, curban.admin, curban.name)
end
end
concommand.Add( "sb_importulxbans",function()
ZerfBans()
end )
[/lua]
I was wondering if the issue was fixed with this that you had to add VIP And all that manually to the SB database so it didn't strip them of their rank every time they joined?
[QUOTE=F14;45709991]I would love the code, whats your steam?[/QUOTE]
[url]http://pastebin.com/KWZ7QkjW[/url] here you go just replace the sban.lua with that. Its a pretty shitty way to do it but it works
What did i do wrong?
// MODULE: sban_mysql.lua //
[ERROR] addons/ulx/lua/ulx/modules/sban_mysql.lua:5: Couldn't load module library!
1. require - [C]:-1
2. unknown - addons/ulx/lua/ulx/modules/sban_mysql.lua:5
3. include - [C]:-1
4. unknown - addons/ulx/lua/ulx/init.lua:28
5. include - [C]:-1
6. unknown - addons/ulx/lua/ulib/modules/ulx_init.lua:2
7. include - [C]:-1
8. unknown - addons/ulib/lua/ulib/init.lua:68
9. include - [C]:-1
10. unknown - addons/ulib/lua/autorun/ulib_init.lua:3
Sorry, you need to Log In to post a reply to this thread.