From 80767b98636e69b93f01d74d8e33401fa114b8ab Mon Sep 17 00:00:00 2001 From: ChocoTaco1 Date: Sun, 11 Dec 2022 20:17:39 -0500 Subject: [PATCH] Vote Bug $missionStartTime isnt set until match starts --- Classic/scripts/autoexec/VoteMenu.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Classic/scripts/autoexec/VoteMenu.cs b/Classic/scripts/autoexec/VoteMenu.cs index 79a3a16..8009f34 100644 --- a/Classic/scripts/autoexec/VoteMenu.cs +++ b/Classic/scripts/autoexec/VoteMenu.cs @@ -286,7 +286,7 @@ function serverCmdStartNewVote(%client, %typeName, %arg1, %arg2, %arg3, %arg4, % { case "VoteKickPlayer": %curTimeLeftMS = ($Host::TimeLimit * 60 * 1000) + $missionStartTime - getSimTime(); - if(%curTimeLeftMS <= 120000) + if(%curTimeLeftMS <= 120000 && $countdownStarted && $MatchStarted && !%isAdmin) { messageClient(%client, "", "\c2Kick votes are restricted at this time."); return; @@ -378,7 +378,7 @@ function serverCmdStartNewVote(%client, %typeName, %arg1, %arg2, %arg3, %arg4, % case "VoteChangeMission": %curTimeLeftMS = ($Host::TimeLimit * 60 * 1000) + $missionStartTime - getSimTime(); - if(%curTimeLeftMS <= 120000) + if(%curTimeLeftMS <= 120000 && $countdownStarted && $MatchStarted && !%isAdmin) { messageClient(%client, "", "\c2Change mission votes are restricted at this time."); return; @@ -712,7 +712,7 @@ function serverCmdStartNewVote(%client, %typeName, %arg1, %arg2, %arg3, %arg4, % case "VoteNextMission": %curTimeLeftMS = ($Host::TimeLimit * 60 * 1000) + $missionStartTime - getSimTime(); - if(%curTimeLeftMS <= 120000) + if(%curTimeLeftMS <= 120000 && $countdownStarted && $MatchStarted && !%isAdmin) { messageClient(%client, "", "\c2Set next mission votes are restricted at this time."); return;