Page 1 of 1

How to check if warmup is running?

Posted: Sat May 23, 2015 1:47 pm
by Mahi
^ this

Posted: Sat May 23, 2015 2:00 pm
by Ayuto
I guess this event gets fired if the warmup starts. http://wiki.sourcepython.com/pages/Event-csgo:round_announce_warmup
And this event is probably called when the warmup ends and the actual match starts. http://wiki.sourcepython.com/pages/Event-csgo:round_announce_match_start

Posted: Sat May 23, 2015 2:10 pm
by satoon101
If you have access to the server's console, you can use the following to print out events as they happen:

Code: Select all

sv_cheats 1
net_showevents 2

Posted: Sat May 23, 2015 4:18 pm
by Mahi
Ahh of course, didn't realize events would be fired. Thanks guys :) !

EDIT: Any method to completely just disable the plugin during warmup? I find it rather stupid to have "if warmup:" everywhere and then set the warmup variable in those events.

Posted: Sat May 23, 2015 4:57 pm
by Ayuto
You could write another plugin that unloads your plugin when warmup has started and loads it again if warmup is over.

Posted: Wed May 27, 2015 5:27 am
by satoon101
To accurately know if the warmup round is going, without having to track it yourself with events, you could find the signature/symbol for CCSGameRules::IsWarmupPeriod. Once you have that, you can call that function to get the current boolean value.