Raised This Month: $ Target: $400
 0% 

[Example] Restricting SteamIDs by File


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
BAILOPAN
Join Date: Jan 2004
Old 03-18-2007 , 22:04   [Example] Restricting SteamIDs by File
Reply With Quote #1

www.cssnation.net approached me today asking how they could restrict access to their server based on a file of SteamIDs. There are many ways to do it, but the best way is to use the admin system.

The admin system allows you to create your own lookup tables and custom admin systems. This script uses that feature to read admins from a file and add them into a custom admin pool. If a steamid is not in this pool, the client is rejected from the server.

The file it reads from is sourcemod/configs/allowed_steamids.txt
Attached Files
File Type: sp Get Plugin or Get Source (steamid_restrict.sp - 997 views - 2.1 KB)
__________________
egg

Last edited by BAILOPAN; 05-21-2008 at 13:43.
BAILOPAN is offline
Gemeni
Senior Member
Join Date: Sep 2007
Location: Sweden
Old 10-07-2007 , 18:06   Re: [Example] Restricting SteamIDs by File
Reply With Quote #2

This is an interesting script... Planing to use it on a member server ...
But then i want to reaload the file on every mapchange. And members can be added or removed based on some criteria.

Is there a way to clear the custom admin pool?

Basically adding:

public OnMapStart()
{
clear admin pool()
ReadAccounts()
}
__________________
--- Growing older is mandatory --
----- Growing up is optional -----
Gemeni is offline
BAILOPAN
Join Date: Jan 2004
Old 10-14-2007 , 00:14   Re: [Example] Restricting SteamIDs by File
Reply With Quote #3

SourceMod's internal admin cache is refreshed on mapchanges.

sm_reloadadmins is a command from basecommands.sp which does the same thing.
__________________
egg
BAILOPAN is offline
duydangle
Senior Member
Join Date: May 2010
Old 08-02-2010 , 20:49   Re: [Example] Restricting SteamIDs by File
Reply With Quote #4

I love this plugin's idea. But I want everybody to sign up, and have to have these commands to be joined the server.
setinfo _name ...
setinfo _pw...
Can you guys make it?. I also want mysql to be supported.
duydangle is offline
Reply


Thread Tools
Display Modes

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 18:48.


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