diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-10-14 21:01:40 +0100 |
---|---|---|
committer | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-10-14 21:01:40 +0100 |
commit | 9a2778eabc7ba968968e41dda9f03525d6c5383d (patch) | |
tree | 6d1c5dc64754d542d68a7f47742a701a4eec9308 /Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut | |
parent | c0a0c7e502f2bc99185d79a485b965f63de7a203 (diff) | |
download | NorthstarMods-9a2778eabc7ba968968e41dda9f03525d6c5383d.tar.gz NorthstarMods-9a2778eabc7ba968968e41dda9f03525d6c5383d.zip |
oh fuck i forgot to commit for a while
Diffstat (limited to 'Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut')
-rw-r--r-- | Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut | 29 |
1 files changed, 6 insertions, 23 deletions
diff --git a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut index 711cbbbcf..be2a10483 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_custom_match_settings_categories.nut @@ -25,31 +25,14 @@ void function OnNorthstarCustomMatchSettingsCategoryMenuOpened() array<string> categories = GetPrivateMatchSettingCategories() array<var> buttons = GetElementsByClassname( GetMenu( "CustomMatchSettingsCategoryMenu" ), "MatchSettingCategoryButton" ) - for ( int i = 0, j = 0; j < categories.len() && i < buttons.len(); i++, j++ ) + foreach ( var button in buttons ) { - Hud_SetEnabled( buttons[ i ], false ) - Hud_SetVisible( buttons[ i ], false ) + Hud_SetEnabled( button, false ) + Hud_SetVisible( button, false ) + } - // skip gamemode/playlist categories for modes that aren't the current one - // todo this fucking breaks everything lmao - //bool gamemode = categories[ j ].find( "#GAMEMODE_" ) == 0 - //if ( gamemode || categories[ j ].find( "#PL_" ) == 0 ) - //{ - // if ( gamemode ) - // { - // if ( categories[ j ].slice( 10 ) != PrivateMatch_GetSelectedMode() ) - // { - // i-- - // continue - // } - // } - // else if ( categories[ j ].slice( 4 ) != PrivateMatch_GetSelectedMode() ) - // { - // i-- - // continue - // } - //} - + for ( int i = 0, j = 0; j < categories.len() && i < buttons.len(); i++, j++ ) + { Hud_SetText( buttons[ i ], Localize( categories[ j ] ) + " ->" ) Hud_SetEnabled( buttons[ i ], true ) Hud_SetVisible( buttons[ i ], true ) |