Raised This Month: $ Target: $400
 0% 

Game Commencing Prevent (without bots)


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Server Management       
neuromancer
Member
Join Date: Apr 2007
Location: Poland
Old 05-14-2008 , 17:07   Game Commencing Prevent (without bots)
Reply With Quote #1

This plugin saves the timeleft and when there is Game Commencing it sets mp_timelimit to the timeleft that has been saved before, so it prevents the maptime reseting every time Game Commencing happens.

If an admin restarts the game using sv_restart the plugin will set the original value of mp_timelimit.

Cvars:
amx_commencing_prevent 1/0 - turning the plugin on and off (default: 1)
Attached Files
File Type: sma Get Plugin or Get Source (commencing_prevent.sma - 1284 views - 1.1 KB)

Last edited by neuromancer; 05-17-2008 at 09:45. Reason: There was a little error in the code, if mp_timelimit is 0 (no timelimit) then it would reset it to 1 instead of leaving it 0
neuromancer is offline
Dr. Jan Itor
Veteran Member
Join Date: Mar 2008
Location: there.
Old 05-15-2008 , 13:50   Re: Game Commencing Prevent (without bots)
Reply With Quote #2

sounds nice would really stop ppl from playing same map forever
__________________
Dr. Jan Itor is offline
draft
Senior Member
Join Date: Jul 2007
Location: Russia, Saint-Petersburg
Old 05-17-2008 , 06:23   Re: Game Commencing Prevent (without bots)
Reply With Quote #3

Very good job.
__________________
draft is offline
ESTCOBS
Junior Member
Join Date: May 2008
Location: Kraków, Poland
Old 05-17-2008 , 14:01   Re: Game Commencing Prevent (without bots)
Reply With Quote #4

Nice plugin !
Get +karma !
__________________
Róót ! xD
ESTCOBS is offline
Stixsmaster
Veteran Member
Join Date: May 2007
Location: I am all around you...I
Old 06-15-2008 , 21:35   Re: Game Commencing Prevent (without bots)
Reply With Quote #5

what does this (without bots) mean? as I just tried this on my CZ server which has 6 bots by default but just to let all no I have the auto_vacate set to 1 and well this plugin just did not work...

---Stixsmaster

P.S. I didnt type in console sv_restart but the mod I run, Halo Mod, uses sv_restart...
__________________
Stixsmaster is offline
Send a message via AIM to Stixsmaster Send a message via MSN to Stixsmaster
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 06-16-2008 , 17:09   Re: Game Commencing Prevent (without bots)
Reply With Quote #6

A. this plugin hooks the restart message so any use of the sv_restart/restartround will be hooked
B. Does the mp_timelimit CVAR become reset at any time? If I have it set to 20.0 and your plugin modifies it to 30.0 will it be 20.0 or 30.0 when the next map changes? (pretending I don't have mp_timelimit set in any of my server's config files, which infact I don't)
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
Stixsmaster
Veteran Member
Join Date: May 2007
Location: I am all around you...I
Old 06-16-2008 , 17:31   Re: Game Commencing Prevent (without bots)
Reply With Quote #7

I tried it...and all it did was reset it back to what my default mp_timelimit was...

---Stixsmaster
__________________
Stixsmaster is offline
Send a message via AIM to Stixsmaster Send a message via MSN to Stixsmaster
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 06-18-2008 , 01:37   Re: Game Commencing Prevent (without bots)
Reply With Quote #8

Clean that code up. Here, I'll post what I've done so far. I'm trying to figure out how to get it to work with bots... I'm not familiar with the restarts and stuff.

Also, use pcvars! They are faster and it is required to get approved.

Quote:
Originally Posted by GHW_Chronic View Post
A. this plugin hooks the restart message so any use of the sv_restart/restartround will be hooked
B. Does the mp_timelimit CVAR become reset at any time? If I have it set to 20.0 and your plugin modifies it to 30.0 will it be 20.0 or 30.0 when the next map changes? (pretending I don't have mp_timelimit set in any of my server's config files, which infact I don't)
If you are that concerned just add it to your server.cfg. Then you won't have to worry at all.
Attached Files
File Type: sma Get Plugin or Get Source (commencing_prevent.sma - 855 views - 1.2 KB)
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."

Last edited by soccdoodcss; 06-18-2008 at 01:47.
soccdoodcss is offline
Send a message via AIM to soccdoodcss
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 06-18-2008 , 16:09   Re: Game Commencing Prevent (without bots)
Reply With Quote #9

you see socc, I have never found it to be the user's responsibility to make sure a plugin works the way it should. It can be the user's responsibility to make sure the plugin is configured and installed properly, fine, but not to have to do extra steps to make it work.

Just add a set_task(0.5,?,0,"",0,"d") gg
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 06-18-2008 , 19:25   Re: Game Commencing Prevent (without bots)
Reply With Quote #10

I don't see why adding it to your server.cfg would be out of the question. You keep plenty of cvars in there that you want to be set to default after map change. I'm assuming you wanted it to set it to your default after map change. I understand what you're saying but in this case it is no big deal, and 99% of people have it saved in their server.cfg.
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."
soccdoodcss is offline
Send a message via AIM to soccdoodcss
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 08:04.


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