diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-11-07 03:53:07 +0000 |
---|---|---|
committer | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-11-07 03:53:07 +0000 |
commit | 35dfd937798d105238db23ea86f90f21be46694b (patch) | |
tree | d0e1ee639bc6177649dbcbde054f1e6094fc054c /Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut | |
parent | e79a58640e1ef1ea1c3c954aefccd36c3cb55286 (diff) | |
download | NorthstarMods-35dfd937798d105238db23ea86f90f21be46694b.tar.gz NorthstarMods-35dfd937798d105238db23ea86f90f21be46694b.zip |
code cleanup, xp, postgame and some small changes
Diffstat (limited to 'Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut')
-rw-r--r-- | Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut | 23 |
1 files changed, 4 insertions, 19 deletions
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut b/Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut index 20d742d06..9fde28ddc 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/sh_northstar_utils.gnut @@ -1,23 +1,15 @@ globalize_all_functions -enum eNorthstarLobbyType +global enum eNorthstarLobbyType { PrivateMatchLobby, // normal vanilla private lobby - IntermissionLobby, // similar to tf1's intermission lobby, chooses next map automatically - CompetitiveLobby // similar to vanilla privates, but with ready up system + IntermissionLobby, // similar to tf1's intermission lobby, chooses next map automatically, can't change settings unless you're host } // whether the server is a modded, northstar server bool function IsNorthstarServer() { - bool isModded = true // TEMP for testing - try - { - // need this in a trycatch because the var might not exist atm - isModded = GetConVarInt( "northstar_is_modded_server" ) == 1 - } catch ( ex ) {} - - return isModded + return GetConVarBool( "ns_is_modded_server" ) } // whether the game should return to the lobby on GameRules_EndMatch() @@ -30,13 +22,6 @@ int function GetNorthstarLobbyType() { if ( !IsNorthstarServer() ) return eNorthstarLobbyType.PrivateMatchLobby - - int lobbyType = eNorthstarLobbyType.PrivateMatchLobby - try - { - // need this in a trycatch because the var might not exist atm - lobbyType = GetConVarInt( "northstar_lobby_type" ) - } catch ( ex ) {} - return lobbyType + return GetConVarInt( "ns_lobby_type" ) }
\ No newline at end of file |