From 924ffd318cb16210a592fa3ef84138676c0acd1f Mon Sep 17 00:00:00 2001 From: jenz Date: Sat, 21 Sep 2024 13:32:16 +0200 Subject: [PATCH] added timer so people can walk during the intermission --- .../scripting/mapchooser_extended_avg_mapend.sp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/mapchooser_extended/scripting/mapchooser_extended_avg_mapend.sp b/mapchooser_extended/scripting/mapchooser_extended_avg_mapend.sp index 550a26b5..0e9058e1 100755 --- a/mapchooser_extended/scripting/mapchooser_extended_avg_mapend.sp +++ b/mapchooser_extended/scripting/mapchooser_extended_avg_mapend.sp @@ -991,12 +991,26 @@ public Action CS_OnTerminateRound(float &delay, CSRoundEndReason &reason) InitiateVote(MapChange_Instant); //feature so mapvote happens at actual mapend } delay = float(total_time); + CreateTimer(0.1, Timer_set_move_type); return Plugin_Changed; } g_DidRoundTerminate = false; return Plugin_Continue; } +public Action Timer_set_move_type(Handle hTimer, Handle dp) +{ + for (int i = 1; i < MaxClients; i++) + { + if (IsValidClient(i)) + { + SetEntityMoveType(i, MOVETYPE_WALK); + //should allow people to run around freely by overwriting pPlayer->AddFlag( FL_FROZEN ); line 3337 in cs_gamerules.cpp + } + } + return Plugin_Handled; +} + public Action Timer_fall_back_map_switch(Handle hTimer, Handle dp) { ForceChangeLevel("ze_random_v9", "nobody voted at mapvote");