View Full Version : routine-timing before real mapchange
ghzero
10-17-2007, 07:46 AM
hello,
please can you tell me whats a safe way for timing an routine that I want to execute before mapchange will done.. my script will make some jumps and set_task so it takes circa 10 secs(some treaded sql-inserts and changes). for a full server to finish. is it best only way to catch to timeleft ever x secs. to timing the start-point for the script?!
Wilson [29th ID]
10-17-2007, 03:55 PM
register_message( get_user_msgid("SVC_INTERMISSION"), "hook_mapchange" );
It hooks when the scores come up and playing is disabled.
ghzero
10-18-2007, 01:56 AM
;7915']register_message( get_user_msgid("SVC_INTERMISSION"), "hook_mapchange" );
It hooks when the scores come up and playing is disabled.
thank you for your answer. do you know how many time(secs.) will the routine have before the server will unload the amxx-plugins for mapchange ?! give it an serverside cvar for that time between start viewing the scoreboard and start loading(=time of unload of plugins?) ?!
some uses mapmanagers what will changelevel use to switch map before timeleft runs out..
so I prefer this register for surely execute my lastscriptlines I want:
//hook when used deagsmapmanager for scripted changelevel before timeleft runs out..
set_task(64.0, "task_LastRound", _, _, _, "d");//64secs.before mp_timelimit runs out call that rountine! bcoz 60 secs. before time runs out the mapmanage init the mapchange with countdown of 5 secs.
Wilson [29th ID]
10-19-2007, 03:24 AM
Look through the nextmap.amxx plugin - you'll probably find a way to throw it in there.
vBulletin® v3.8.6, Copyright ©2000-2012, Jelsoft Enterprises Ltd.