AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   Automatic Restart - Prevent fast-connecters to get money (https://forums.alliedmods.net/showthread.php?t=9143)

ToT | V!PER 01-07-2005 07:06

Automatic Restart - Prevent fast-connecters to get money
 
1 Attachment(s)
This plugin simply does a auto-restart after a defined amount of time. The restart occurs AFTER game commencing (both teams got players first).

This is usefull to prevent fast-connectors get easy and fast money for the 2nd round. So nearly everyone will be forced to play the pistolround on public-servers.

Code:
#include <amxmodx> public restart_time()      set_task (get_cvar_float("amx_autorestart"),"restart_map",0)   public restart_map() {           set_hudmessage(0, 100, 200, 0.05, 0.65, 2, 0.02, 6.0, 0.01, 0.1, 2)           show_hudmessage(0,"[AMXX] Automatic Round-Restart!")           set_cvar_float("sv_restart",2.0)         return PLUGIN_HANDLED    }   public plugin_init() {      register_plugin("Auto-Restart","1.00","ToT | V!PER")      register_event("TextMsg","restart_time","a","2&#Game_C")      register_cvar("amx_autorestart","20.0")    return PLUGIN_CONTINUE     }

XxAvalanchexX 01-07-2005 16:07

When you start the plugin you have it restart in 20.0 seconds. After it restarts, you set the amount of time to 2.0 seconds. Why?

ToT | V!PER 01-08-2005 04:03

Quote:

Originally Posted by XxAvalanchexX
When you start the plugin you have it restart in 20.0 seconds. After it restarts, you set the amount of time to 2.0 seconds. Why?

No. It checks for the event "game commencing", sets a timer for 20 seconds and executes a servercmd -> sv_restart 2 (restartround after 2 seconds)

onedamage 03-25-2005 20:18

any way u can add a message saying or something saying 'the round will restart', up untill the round acutally does restart ?

hhhmm, i wonder if u still support this ......january.....little far off....

ToT | V!PER 03-25-2005 22:06

Quote:

Originally Posted by onedamage
any way u can add a message saying or something saying 'the round will restart', up untill the round acutally does restart ?

hhhmm, i wonder if u still support this ......january.....little far off....

show_hudmessage(0,"[AMXX] Automatic Round-Restart!")

Hm, there is a hud-message beeing displayed. What message should be needed else?

onedamage 03-25-2005 22:28

my mistake, i must have not realized when i was playing.

if the case is that it appears just before restarting:

how can i have it last longer ?
such as, i'd like it to last the whole 20 seconds, is this possible ?

v3x 03-26-2005 00:02

http://amxmodx.org/funcwiki.php?go=func&id=28

onedamage 03-26-2005 00:03

hey nice, thx v3x, i'll look into it.

ToT | V!PER 03-26-2005 06:18

Well, i could implement a "timer" function, so it counts down to restart. But this would override other messages that would be displayed i think. So i´ve made my choice to simply display a message shortly before restart.

onedamage 03-26-2005 10:23

i understand your point,

the problem i have is that people are just starting to realize that there is a round restart :o

since its only happens once per map, people dont catch onto it quick, thats
why for me a message from the beginning of the map till execution is important.

to many people whinning that they just killed got a 5 kill streak, but then the round restarted,

if there was a message on their screen during the first 20 seconds, then i can call them idiots :roll:


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

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