aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/lobby/_private_lobby.gnut8
1 files changed, 4 insertions, 4 deletions
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/lobby/_private_lobby.gnut b/Northstar.CustomServers/mod/scripts/vscripts/lobby/_private_lobby.gnut
index 08cc9d0b..388f4794 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/lobby/_private_lobby.gnut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/lobby/_private_lobby.gnut
@@ -37,6 +37,10 @@ void function SetupPrivateMatchUIVarsWhenReady()
bool function ClientCommandCallback_PrivateMatchLaunch( entity player, array<string> args )
{
+ if ( GetConVarBool( "ns_private_match_only_host_can_start" ) )
+ if ( !NSIsPlayerIndexLocalPlayer( player.GetPlayerIndex() ) )
+ return true
+
if ( file.startState == ePrivateMatchStartState.STARTING )
{
// cancel start if we're already mid-countdown
@@ -46,10 +50,6 @@ bool function ClientCommandCallback_PrivateMatchLaunch( entity player, array<str
}
else
{
- if ( GetConVarBool( "ns_private_match_only_host_can_start" ) )
- if ( !NSIsPlayerIndexLocalPlayer( player.GetPlayerIndex() ) )
- return true
-
// start match
file.startState = ePrivateMatchStartState.STARTING
thread StartMatch()