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

Auto Remove Password ( auto_remove_pass )


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
_KaszpiR_
AMX Mod X Beta Tester
Join Date: Feb 2004
Location: Warsaw, Poland
Old 08-19-2006 , 12:50   Auto Remove Password ( auto_remove_pass )
Reply With Quote #1

Description
* This plugin will execute defined comamnds on server if it's empty for some time. By default it was used as only password remover, but it was extended to handle execution of extra commands (like executing some config)
* So if someone got a server for rent and the clan after war forget to execute some basic commands - here you got this plugin.

Detailes description
Usage:
- open file addons\amx\config\amx.cfg (just an example)
- add these lines to amx.cfg only if you don't like defaults:
arp_checkdelay <delay>
arp_checktimes <number of checks>
arp_command <string>
arp_setpass <string>
- save the changes to file amx.cfg

CVAR explanation
arp_checkdelay <X> - delay in seconds (replace <X> with seconds) between each check (default is 60 seconds)
arp_checktimes <X> - (replace <X> with number) number of checks before plugin removes password from the server (default is 5 checks)
If you leave defaults (you don't add any lines to admin.cfg) then the plugin will remove the password from the server after 5 minutes (60 seconds * 5 = 300 seconds = 5 minutes).
arp_command <string> - execute the extra command (replace <string> with commands set without quotes) after the time (after setting/clearing sv_password)
arp_setpass <string> - (replace <string> with password set without quotes) set the given sv_password to the string value, set to arp_setpass "" to clear the password
arp_bots <X> - the number <X> can be
1 treat bots as real players, the HLTV is also
0 - do not reat bots as real players (default)

Example 1 (basic setting pass)
Put to amxx.cfg
Code:
arp_checkdelay 30
arp_checktimes 3
arp_setpass "some_server_password"
Example 2 (basic clearing pass)
Put to amxx.cfg
Code:
arp_checkdelay 30
arp_checktimes 3
arp_setpass "";// clearing pass
Example 2 (executing additional commands after setting pass)
Put to amxx.cfg
Code:
arp_checkdelay 30
arp_checktimes 3
arp_setpass "for_rent" ; // clear sv_password in this way
arp_command "exec server.cfg;amx_matchstop" ;
Example 3 (executing a config):
Put to amxx.cfg
Code:
arp_checkdelay 30
arp_checktimes 3
arp_command "exec clear_server.cfg"
arp_setpass "" ; // clear sv_password in this way
and in cstrtike\clear_server.cfg you place some commands you want to execute:
Code:
writeip
writeid
servercfgfile server.cfg
mapcyclefile mapcycyle.txt
say Defaults Loaded
exec server.cfg
changelevel de_dust
Extra
Originally made by Marach for AMX Mod (it was only clearing password)
(c) Copyright 2003 by Marach ([email protected], ICQ: 242122535, AIM: marach24, MSN IM: [email protected])

This file is provided as is (no warranties).
version 1.2 by _KaszpiR_ http://nvt.prv.pl
Attached Files
File Type: sma Get Plugin or Get Source (auto_remove_pass.sma - 1403 views - 4.6 KB)
__________________
= Ave Cesar, morituri Te salutant. = http://nvt.prv.pl = http://hlds.pl/
_KaszpiR_ is offline
Xanimos
Veteran Member
Join Date: Apr 2005
Location: Florida
Old 12-12-2006 , 13:06   Re: Auto Remove Password ( auto_remove_pass )
Reply With Quote #2

The normal auto remove password on empty server has already been ported by GHW_Chronic here http://forums.alliedmods.net/showthread.php?t=17450 so I would recommend changing the name since you did change the functionality. Auto config on empty server or something similar.
Xanimos is offline
Send a message via AIM to Xanimos Send a message via MSN to Xanimos
s p l i t
Senior Member
Join Date: May 2006
Location: US, NC
Old 12-12-2006 , 13:39   Re: Auto Remove Password ( auto_remove_pass )
Reply With Quote #3

In some places you need to change amx.cfg to amxx.cfg and please format the code so that it is readable.
s p l i t is offline
Send a message via AIM to s p l i t Send a message via MSN to s p l i t
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 12-14-2006 , 19:50   Re: Auto Remove Password ( auto_remove_pass )
Reply With Quote #4

Quote:
Originally Posted by s p l i t View Post
In some places you need to change amx.cfg to amxx.cfg and please format the code so that it is readable.
This is true, in your how to: you need to change amx.cfg -> amxx.cfg
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 12-20-2006 , 21:08   Re: Auto Remove Password ( auto_remove_pass )
Reply With Quote #5

i dont think this works well enough to be approved as well you should read from a cfg rather than a cvar. maybe try again later.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
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 01:59.


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