Closed Lidbetter closed 2 years ago
So looks like this is intentional: https://github.com/splewis/csgo-practice-mode/blob/afab77b039b05199e869dcb438c4a191de9f83d1/scripting/practicemode.sp#L855-L863
Without introducing anymore state, perhaps one way we could address this is to set g_AutostartCvar.IntValue 0
when disabling prac mode (and re-reading from cfg file when (re)enabled (via ingame menu or command))
I would agree the current behavior is a little strange in the way you describe. IMO, once practicemode is turned off by players on a server, it shouldn't be restarted without a map change.
I think I would prefer doing that without actually having to modify the g_AutostartCvar
value.
Expected behavior
When using
sm_practicemode_autostart 1
I expect:sm_exitpractice
) thenmp_restartgame 1
/ get5 scrim, practice mode remains disabledActual behavior
When using
sm_practicemode_autostart 1
I experience:Steps to reproduce
csgo/cfg/practicemode.cfg
havesm_practicemode_autostart 1
sm_exitpractice
mp_restartgame 1
Practice mode is also re-enabled on round restart even if
sm_practicemode_can_be_started 0
For now I have worked around this issue (because it is nice to have the server start in prac mode) by adding the following lines to the cfg files which get5 executes when starting a scrim