diff options
Diffstat (limited to 'Northstar.Client/mod/scripts')
-rw-r--r-- | Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut | 15 |
1 files changed, 8 insertions, 7 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 de4a663e..97072ab5 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut @@ -127,6 +127,14 @@ void function UpdateShownPage() Hud_SetVisible( Hud_GetChild( menu, "NextModeIcon" ), false ) Hud_SetVisible( Hud_GetChild( menu, "NextGameModeName" ), false ) + if ( NSGetServerCount() == 0 ) + { + Hud_SetEnabled( serverButtons[ 0 ], true ) + Hud_SetVisible( serverButtons[ 0 ], true ) + SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_NOSERVERS" ) + return + } + for ( int i = 0; ( file.page * BUTTONS_PER_PAGE ) + i < NSGetServerCount() - 1 && i < serverButtons.len(); i++ ) { int serverIndex = ( file.page * BUTTONS_PER_PAGE ) + i @@ -135,13 +143,6 @@ void function UpdateShownPage() Hud_SetVisible( serverButtons[ i ], true ) SetButtonRuiText( serverButtons[ i ], NSGetServerName( serverIndex ) ) } - - if ( NSGetServerCount() == 0 ) - { - Hud_SetEnabled( serverButtons[ 0 ], true ) - Hud_SetVisible( serverButtons[ 0 ], true ) - SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_NOSERVERS" ) - } } void function OnServerFocused( var button ) |