diff options
author | Barichello <artur@barichello.me> | 2022-01-20 17:26:38 -0300 |
---|---|---|
committer | Barichello <artur@barichello.me> | 2022-01-20 17:26:38 -0300 |
commit | d72946a3ddcba685472b3f4b76c70dff00133d78 (patch) | |
tree | 2eba8744b3d028a9b3bf59355c5f56b5f9111b73 /Northstar.Client/mod/scripts/vscripts | |
parent | ae5b80278e16843ecc1823fc817ea7aa0c24d843 (diff) | |
download | NorthstarMods-d72946a3ddcba685472b3f4b76c70dff00133d78.tar.gz NorthstarMods-d72946a3ddcba685472b3f4b76c70dff00133d78.zip |
Fix crash when changing remote from an empty masterserver
Diffstat (limited to 'Northstar.Client/mod/scripts/vscripts')
-rw-r--r-- | Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut | 4 |
1 files changed, 1 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 0f96d2e4..194c0831 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut @@ -828,7 +828,7 @@ void function DisplayFocusedServerInfo( int scriptID) { if (scriptID == 999 || scriptID == -1 || scriptID == 16) return - if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed ) + if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed || file.serversArrayFiltered.len() == 0) return var menu = GetMenu( "ServerBrowserMenu" ) @@ -843,9 +843,7 @@ void function DisplayFocusedServerInfo( int scriptID) // text panels Hud_SetVisible( Hud_GetChild( menu, "LabelDescription" ), true ) Hud_SetVisible( Hud_GetChild( menu, "LabelMods" ), false ) - //RuiSetGameTime( textRui, "startTime", -99999.99 ) // make sure it skips the whole animation for showing this Hud_SetText( Hud_GetChild( menu, "LabelDescription" ), NSGetServerDescription( file.serversArrayFiltered[ serverIndex ].serverIndex ) + "\n\nRequired Mods:\n" + FillInServerModsLabel( file.serversArrayFiltered[ serverIndex ].serverIndex )) - //Hud_SetText( Hud_GetChild( menu, "LabelMods" ), FillInServerModsLabel( file.serversArrayFiltered[ serverIndex ].serverIndex ) ) // map name/image/server name string map = file.serversArrayFiltered[ serverIndex ].serverMap |