diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-12-26 04:24:26 +0000 |
---|---|---|
committer | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-12-26 04:24:26 +0000 |
commit | dc60309beafb22e34d91593417b09d84e9442089 (patch) | |
tree | ebe5253297db76b0d9f6db3acef7f54bf6a18908 /Northstar.Client/mod/scripts/vscripts/ui | |
parent | e4faa247edaf389d4d52e3a3129af540bb19a0ac (diff) | |
download | NorthstarMods-dc60309beafb22e34d91593417b09d84e9442089.tar.gz NorthstarMods-dc60309beafb22e34d91593417b09d84e9442089.zip |
evac, dropship, bleedout, flyout, private lobby, fastball and server browser fixes
Diffstat (limited to 'Northstar.Client/mod/scripts/vscripts/ui')
-rw-r--r-- | Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut index 03009764..19a544cc 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut @@ -6,6 +6,7 @@ const int BUTTONS_PER_PAGE = 15 struct { int page = 0 int lastSelectedServer = 0 + bool serverListRequestFailed = false } file void function AddNorthstarServerBrowserMenu() @@ -52,6 +53,7 @@ void function RefreshServers( var button ) return file.page = 0 + file.serverListRequestFailed = false NSClearRecievedServerList() NSRequestServerList() @@ -101,7 +103,8 @@ void function WaitForServerListRequest() while ( NSIsRequestingServerList() ) WaitFrame() - if ( !NSMasterServerConnectionSuccessful() ) + file.serverListRequestFailed = !NSMasterServerConnectionSuccessful() + if ( file.serverListRequestFailed ) SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_CONNECTIONFAILED" ) else UpdateShownPage() @@ -152,7 +155,7 @@ void function UpdateShownPage() void function OnServerFocused( var button ) { - if ( NSIsRequestingServerList() || !NSMasterServerConnectionSuccessful() || NSGetServerCount() == 0 ) + if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed ) return var menu = GetMenu( "ServerBrowserMenu" ) @@ -201,7 +204,7 @@ string function FormatServerDescription( int server ) void function OnServerSelected( var button ) { - if ( NSIsRequestingServerList() || !NSMasterServerConnectionSuccessful() || NSGetServerCount() == 0 ) + if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed ) return int serverIndex = file.page * BUTTONS_PER_PAGE + int ( Hud_GetScriptID( button ) ) |