Raised This Month: $51 Target: $400
 12% 

[Any] Server Whitelist Advanced (1.5.0)


Post New Thread Reply   
 
Thread Tools Display Modes
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-07-2015 , 12:25   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #41

Quote:
Originally Posted by Fyren View Post
It was a change in 1.7 that made your mistake an error. Before 1.7, it would compile.
Thanks. I did test by only changing the compile.exe in my 1.7 folder; meaning I wasn't using the older .inc; which seems to have lead to my problem and confusion.

Sorry for the panic/confusion and thanks again.

Red

EDIT : To sum it up, pre-1.7, using functions without their parenthesis was allowed; under 1.6,
Code:
public OnPluginStart()
{
	new bar = foo;
	bar++;
}
foo() { }
compile fine without errors or warning (build sm-1.6-hg4131); though calling on bar without its increment would have work
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work

Last edited by RedSword; 03-07-2015 at 12:45.
RedSword is offline
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-07-2015 , 16:21   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #42

1.3.0 is out :
  • Added autovouch (see whitelist_autovouch and whitelist_autovouch_mintimeout). It is now possible to let non-whitelisted player join if a whitelist player or an admin is present. Disabled by default.
  • Added support for AuthId_Steam3 ([U:1:234567] steamId format)
  • Fixed a possible bug in sm_whitelist_exist when checking a Steam Group Id (bug present from 1.1.0 to 1.2.1)
  • Fixed a bug in sm_whitelist_remove when removing a Steam Group Id and the players were already in the whitelist cache (Steam Group status validation wouldn't be redone; now that's the case).
  • Updated to compile with 1.7 compiler (sm_whitelist_exist bug and replaced GetClientAuthString by GetClientAuthId)
  • Changed default whitelist.txt to add a exemple of Steam3 Id (both in code and in attachment.

Quote:
Originally Posted by midnight9 View Post
That would be great As for l4d2 it would have to be on a timer, so checks lets say 60 seconds after first player connect, and do one check and only check when a player joins an empty server. Not on every player connection. So even if member leaves server half way through the match, the game can still go on, and new players (non member) can connect to the server, and the member check will be done again once server gets empty and a player will connect to an empty server. Not sure if that make sense, but i think this method could apply to other games as well.
Currently as long as someone respecting whitelist_autovouch value is present, someone can join. You might want to set whitelist_autovouch_mintimeout to 60 in your scenario. However note that if someone join while there is an admin, and that then the admin left, new players wouldn't be able to join. I'll add that soon... mmm

Red
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work
RedSword is offline
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-07-2015 , 17:50   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #43

1.3.1 is out :
  • Added "invasive" autovoucher (whitelist_autovouch = 3).
  • This makes people temporarily whitelisted as long as there is someone whitelisted (even temporarily).

Quote:
Originally Posted by midnight9 View Post
That would be great As for l4d2 it would have to be on a timer, so checks lets say 60 seconds after first player connect, and do one check and only check when a player joins an empty server. Not on every player connection. So even if member leaves server half way through the match, the game can still go on, and new players (non member) can connect to the server, and the member check will be done again once server gets empty and a player will connect to an empty server. Not sure if that make sense, but i think this method could apply to other games as well.
Try with whitelist_autovouch = 3 and whitelist_autovouch_mintimeout = 60.
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work
RedSword is offline
midnight9
Senior Member
Join Date: Nov 2012
Old 03-07-2015 , 20:03   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #44

Quote:
Originally Posted by RedSword View Post
1.3.0 is out :
  • Added autovouch (see whitelist_autovouch and whitelist_autovouch_mintimeout). It is now possible to let non-whitelisted player join if a whitelist player or an admin is present. Disabled by default.
  • Added support for AuthId_Steam3 ([U:1:234567] steamId format)
  • Fixed a possible bug in sm_whitelist_exist when checking a Steam Group Id (bug present from 1.1.0 to 1.2.1)
  • Fixed a bug in sm_whitelist_remove when removing a Steam Group Id and the players were already in the whitelist cache (Steam Group status validation wouldn't be redone; now that's the case).
  • Updated to compile with 1.7 compiler (sm_whitelist_exist bug and replaced GetClientAuthString by GetClientAuthId)
  • Changed default whitelist.txt to add a exemple of Steam3 Id (both in code and in attachment.



Currently as long as someone respecting whitelist_autovouch value is present, someone can join. You might want to set whitelist_autovouch_mintimeout to 60 in your scenario. However note that if someone join while there is an admin, and that then the admin left, new players wouldn't be able to join. I'll add that soon... mmm

Red
Thanks alot, i will do some testing and if there's any problems will let you know.
Quote:
Currently as long as someone respecting whitelist_autovouch value is present, someone can join. You might want to set whitelist_autovouch_mintimeout to 60 in your scenario. However note that if someone join while there is an admin, and that then the admin left, new players wouldn't be able to join. I'll add that soon... mmm
Yea in my case, I think this is necessary thing to have, since lets say im hosting a game with 7 no whitelisted players, and i have to leave for whatever reason. So they wont be able to get 8th player in, and if more leaves they wont get any replacments (non whitelisted) meaning game will become either unbalanced or pointless to play (not even teams, not enough players). But thanks for your effort, much appreciated
midnight9 is offline
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-07-2015 , 20:41   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #45

Quote:
Originally Posted by midnight9 View Post
Yea in my case, I think this is necessary thing to have, since lets say im hosting a game with 7 no whitelisted players, and i have to leave for whatever reason. So they wont be able to get 8th player in, and if more leaves they wont get any replacments (non whitelisted) meaning game will become either unbalanced or pointless to play (not even teams, not enough players). But thanks for your effort, much appreciated
But this also mean that they will be able to continue and change map and keep on playing since they initially joined when a permanent-whitelisted user was there, even if that user leaves.

EDIT : As per Wolfseye's suggestion, I added a How-to-install

Quote:
Originally Posted by litt89 View Post
[...] what about add a support of steamID3? it would be a relly nice 'cose, for example, No More Room In Hell using only steamID3 [...]
I added SteamId3 "native" support in a previous version (by native I mean "handled correctly" by my plugin; I doubt you were able to use [U:xx] SteamIds as correctly as STEAM_0:1:23456 SteamIds)

Quote:
Originally Posted by litt89 View Post
Well, nevermind Updating of SorceMod fix the problem Everything works great now
When you said that, did you mean that a SM update fixed SourceBans OR that a SM update fixed the SteamID3 thing ?

Thank you,

Red
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work

Last edited by RedSword; 03-07-2015 at 21:59.
RedSword is offline
midnight9
Senior Member
Join Date: Nov 2012
Old 03-08-2015 , 08:35   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #46

Quote:
But this also mean that they will be able to continue and change map and keep on playing since they initially joined when a permanent-whitelisted user was there, even if that user leaves
Well yes, i guess that may not work well in some games, but then in games like L4D2, there is hardly anyone that will switch to new campaign after the current one is finished and if they do, they defo wont play more than 2 campaigns in a row.
So im thinking at the start whitelist_autovouch would be set to "1", so it allows non listed join as long as there is someone whitelisted connected, after 60 seconds the check is being done, and if whitlisted is present the whitelist_autovouch is being set to "3" so if i understood correctly, no matters whos on the server(whitelisted or not) new players can join, right? then on last player disconnect whitelist_autovouch is being set back to "1" (im using a plugin that hooks last player disconnect, and it triggers some function after X time of the last player leaving the server, so im guessing that could be used)
There's probably alost easier and far better way to walk this around, but im not a coder so im just thinking how this could be done from my perspective. Obviously im not expecting you to do anything, since im sure for most games your plugin will perfectly work the way it is now.

BTW, have You considered using HTTP to fetch steamgrouop via cURL extension instead of the current steamtools method. I belive steam tools only works with Source 2009 engine, and if im not mistaken with cURL you could have more game options, such as CS:S, CS:GO, TF2 and of cource Left 4 Dead 1/2.
Here's plugin that uses cURL
https://forums.alliedmods.net/showthread.php?t=145767

Again, just an idea
Thanks for all your work
Regards
midnight9 is offline
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-08-2015 , 14:49   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #47

Quote:
Originally Posted by midnight9 View Post
Well yes, i guess that may not work well in some games, but then in games like L4D2, there is hardly anyone that will switch to new campaign after the current one is finished and if they do, they defo wont play more than 2 campaigns in a row.
So im thinking at the start whitelist_autovouch would be set to "1", so it allows non listed join as long as there is someone whitelisted connected, after 60 seconds the check is being done, and if whitlisted is present the whitelist_autovouch is being set to "3" so if i understood correctly, no matters whos on the server(whitelisted or not) new players can join, right? then on last player disconnect whitelist_autovouch is being set back to "1" (im using a plugin that hooks last player disconnect, and it triggers some function after X time of the last player leaving the server, so im guessing that could be used)
There's probably alost easier and far better way to walk this around, but im not a coder so im just thinking how this could be done from my perspective. Obviously im not expecting you to do anything, since im sure for most games your plugin will perfectly work the way it is now.

BTW, have You considered using HTTP to fetch steamgrouop via cURL extension instead of the current steamtools method. I belive steam tools only works with Source 2009 engine, and if im not mistaken with cURL you could have more game options, such as CS:S, CS:GO, TF2 and of cource Left 4 Dead 1/2.
Here's plugin that uses cURL
https://forums.alliedmods.net/showthread.php?t=145767

Again, just an idea
Thanks for all your work
Regards
1- Why not simply start with whitelist_autovouch being set to "3" ? It is a bit complicated to come up with something that would apply in a campaign change but not in a map-section change; because for SM both are considered normal map change AFAIK. If I implement what you're saying people will get kicked on map-section change if the initial perm-whitelisted people did quit. Would that be wanted ? I believe I can come up with such a timer; thought I'm not sure it would be useful.

2- Even though CSS started differing from TF2, SteamTools still works for CSS. But yeah, it might be a good idea; do you have any sample as to how to check if someone is in a steam group via HTTP request ? Or I'll check more on SteamWorks... That's definitely in my todo :$ (I thought SteamTools would have become ported for more and more games, but it seems that SteamWorks took its place instead :$; and it was recently updated to include Steam Group Ids; it wasn't at the time I made the plugin)
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work

Last edited by RedSword; 03-08-2015 at 15:21.
RedSword is offline
midnight9
Senior Member
Join Date: Nov 2012
Old 03-08-2015 , 16:23   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #48

Quote:
Originally Posted by RedSword View Post
1- Why not simply start with whitelist_autovouch being set to "3" ? It is a bit complicated to come up with something that would apply in a campaign change but not in a map-section change; because for SM both are considered normal map change AFAIK. If I implement what you're saying people will get kicked on map-section change if the initial perm-whitelisted people did quit. Would that be wanted ? I believe I can come up with such a timer; thought I'm not sure it would be useful.

2- Even though CSS started differing from TF2, SteamTools still works for CSS. But yeah, it might be a good idea; do you have any sample as to how to check if someone is in a steam group via HTTP request ? Or I'll check more on SteamWorks... That's definitely in my todo :$ (I thought SteamTools would have become ported for more and more games, but it seems that SteamWorks took its place instead :$; and it was recently updated to include Steam Group Ids; it wasn't at the time I made the plugin)
I think i may have missunderstood the way it works, i will have to give it some testing, cuz what i want is simply to stop no whitelisted connecting/ forcing an empty server unless. So if i set it to 3 the first player that connects if its not whitelisted it will get kicked right? cuz it will only allow connect when there is allready someone on the server, unless i got that wrong again. Thats why i thought it has to be set to 1 to start with ,and then pass the check set to 3, so as long as there are ppl on the server, new players can join etc, and once they all leave it will be set back to 1, wich i could probably add to my existing plugin , i mean i could add 1 line to change cvar to 1 when server is empty. So all i would have to do is just make it change the cvar from 1 to 3 after passed check. But yea on map change its not gonna work, so i guess it only applies to me, but if you could think of a simple timer for cvar change that would be usefull, at least for me i mean like change whitelist_autovouch to 3 after x time.
Btw i tried compile it localy and i was getting errors on all lines containing "GetClientAuthId" any idea?

As for cURL, i think the plugin i posted is allready doing that no?
This plugin reads all players from Steam Community group XML member lists (via HTTP), based on a config file, and adds them to the admin cache whenever the admin cache is refreshed (manually or at map start)

Thought thats what it does checking for members via XML (http://steamcommunity.com/gid/103582...listxml/?xml=1)
think its checking steamID64
unless i got it wrong.
midnight9 is offline
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Old 03-08-2015 , 16:38   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #49

Quote:
Originally Posted by midnight9 View Post
I think i may have missunderstood the way it works, i will have to give it some testing, cuz what i want is simply to stop no whitelisted connecting/ forcing an empty server unless. So if i set it to 3 the first player that connects if its not whitelisted it will get kicked right? cuz it will only allow connect when there is allready someone on the server, unless i got that wrong again. Thats why i thought it has to be set to 1 to start with ,and then pass the check set to 3, so as long as there are ppl on the server, new players can join etc, and once they all leave it will be set back to 1, wich i could probably add to my existing plugin , i mean i could add 1 line to change cvar to 1 when server is empty. So all i would have to do is just make it change the cvar from 1 to 3 after passed check. But yea on map change its not gonna work, so i guess it only applies to me, but if you could think of a simple timer for cvar change that would be usefull, at least for me i mean like change whitelist_autovouch to 3 after x time.
Btw i tried compile it localy and i was getting errors on all lines containing "GetClientAuthId" any idea?

As for cURL, i think the plugin i posted is allready doing that no?
This plugin reads all players from Steam Community group XML member lists (via HTTP), based on a config file, and adds them to the admin cache whenever the admin cache is refreshed (manually or at map start)

Thought thats what it does checking for members via XML (http://steamcommunity.com/gid/103582...listxml/?xml=1)
think its checking steamID64
unless i got it wrong.
1- I think _autovouch set to 3 would do what you describe. No need to change it to 1.

Quote:
So if i set it to 3 the first player that connects if its not whitelisted it will get kicked right? cuz it will only allow connect when there is allready someone on the server, unless i got that wrong again.
Exactly. But not if the first player is automatically reconnecting between two maps (when a map change, all users are disconnected and reconnected).

Also if your server gets to be empty not-between two maps (i.e. all users disconnecting by themselves), then the first player to join would have to be whitelisted.

2- The GetClientAuthId errors comes from the fact that you aren't using SM 1.7; in SM 1.7 the other method to get the client SteamId gets deprecated.

3- My bad; I overlooked that link :$. But I still wonder if there is a way to look for a single individual in a request (when that user connects); that way I don't cache possibly hundreds of thousands people in a group.

Red

EDIT : Thinking about it a 2nd time about it, caching everyone might seem ok (because people probably won't add public groups), and adding to a trie (hashmap) since SM 1.6 is in O(1); so I guess I'd go for the HTTP method; which would even allow more mods

I'll try to implement cURL this week
__________________
My plugins :
Red Maze
Afk Bomb
RAWR (per player/rounds Awp Restrict.)
Kill Assist
Be Medic

You can also Donate if you appreciate my work

Last edited by RedSword; 03-08-2015 at 18:11.
RedSword is offline
midnight9
Senior Member
Join Date: Nov 2012
Old 03-08-2015 , 20:21   Re: [Any] Server Whitelist Advanced (1.2.1)
Reply With Quote #50

Quote:
Originally Posted by RedSword View Post
1- I think _autovouch set to 3 would do what you describe. No need to change it to 1.



Exactly. But not if the first player is automatically reconnecting between two maps (when a map change, all users are disconnected and reconnected).

Also if your server gets to be empty not-between two maps (i.e. all users disconnecting by themselves), then the first player to join would have to be whitelisted.

2- The GetClientAuthId errors comes from the fact that you aren't using SM 1.7; in SM 1.7 the other method to get the client SteamId gets deprecated.

3- My bad; I overlooked that link :$. But I still wonder if there is a way to look for a single individual in a request (when that user connects); that way I don't cache possibly hundreds of thousands people in a group.

Red

EDIT : Thinking about it a 2nd time about it, caching everyone might seem ok (because people probably won't add public groups), and adding to a trie (hashmap) since SM 1.6 is in O(1); so I guess I'd go for the HTTP method; which would even allow more mods

I'll try to implement cURL this week
Well thats what i thought, and since in l4d2 usualy 8 players connects at the same time from lobby, there is no guarantee that the first players that will connect is the whitelisted one, so it has to be on timer, so all players can connect before it will check. I will have a look, if setting it to 3 wont be any good i may try something else.
As for cURL glad to hear that
midnight9 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:07.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode