From 67611e7fad615b33db8c4751b3e61ff44a630071 Mon Sep 17 00:00:00 2001 From: Connie Price Date: Tue, 28 Dec 2021 18:26:54 +0000 Subject: Fixed the game erroring when disembarking from a titan and the player has a weapon missing "menu_category" equipped (like titan weapons). --- .../mod/scripts/vscripts/mp/_titan_transfer.nut | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/_titan_transfer.nut b/Northstar.CustomServers/mod/scripts/vscripts/mp/_titan_transfer.nut index 7b126cd0..c84e6aba 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/mp/_titan_transfer.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/_titan_transfer.nut @@ -178,7 +178,12 @@ void function GiveWeaponsFromStoredArray( entity player, array sto UpdateProScreen( player, weapon ) } - string weaponCategory = GetWeaponInfoFileKeyField_GlobalString( weapon.GetWeaponClassName(), "menu_category" ) + string weaponCategory = "" + if ( IsWeaponKeyFieldDefined(weapon.GetWeaponClassName(), "menu_category") ) + { + weaponCategory = GetWeaponInfoFileKeyField_GlobalString( weapon.GetWeaponClassName(), "menu_category" ) + } + if ( weaponCategory == "at" || weaponCategory == "special" ) // refill AT/grenadier ammo stockpile { int defaultTotal = weapon.GetWeaponSettingInt( eWeaponVar.ammo_default_total ) -- cgit v1.2.3 From c542cd8368db1d979b0c149e81390585c7e475fa Mon Sep 17 00:00:00 2001 From: Barichello Date: Tue, 28 Dec 2021 16:03:06 -0300 Subject: Add portuguese translations --- .../northstar_client_localisation_portuguese.txt | 216 +++++++++++++++++++++ .../mod/resource/northstar_custom_portuguese.txt | 69 +++++++ 2 files changed, 285 insertions(+) create mode 100644 Northstar.Client/mod/resource/northstar_client_localisation_portuguese.txt create mode 100644 Northstar.Custom/mod/resource/northstar_custom_portuguese.txt diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_portuguese.txt b/Northstar.Client/mod/resource/northstar_client_localisation_portuguese.txt new file mode 100644 index 00000000..332d25f8 --- /dev/null +++ b/Northstar.Client/mod/resource/northstar_client_localisation_portuguese.txt @@ -0,0 +1,216 @@ +"lang" +{ + "Language" "portuguese" + "Tokens" + { + "MENU_LAUNCH_NORTHSTAR" "Abrir Northstar" + "MENU_TITLE_MODS" "Mods" + "RELOAD_MODS" "Recarregar Mods" + + "DIALOG_TITLE_INSTALLED_NORTHSTAR" "Obrigado por instalar Northstar!" + "AUTHENTICATION_AGREEMENT_DIALOG_TEXT" "Para o Northstar funcionar é necessário autenticar com o servidor mestre Northstar. Isso requer enviar seu token da Origin para o servidor, ele não será utilizado pra outros propósitos. +Clique em Sim se você concorda. Esta escolha pode ser alterada a qualquer momento no menu de mods." + "BACK_AUTHENTICATION_AGREEMENT" "Aceitação de autorização" + "AUTHENTICATION_AGREEMENT" "Aceitação de autorização" + "AUTHENTICATION_AGREEMENT_RESTART" "Você precisa reiniciar o Titanfall 2 para esta mudança ter efeito." + + "MENU_TITLE_SERVER_BROWSER" "Lista de servidores" + "NS_SERVERBROWSER_NOSERVERS" "Nenhum servidor encontrado" + "NS_SERVERBROWSER_WAITINGFORSERVERS" "Aguardando servidores..." + "NS_SERVERBROWSER_CONNECTIONFAILED" "Falha de conexão!" + "REFRESH_SERVERS" "Atualizar" + + "MENU_TITLE_CONNECT_PASSWORD" "Conectar com senha" + "MENU_CONNECT_MENU_CONNECT" "Conectar" + + "PRIVATE_MATCH_PAGE_PREV" "Página anterior" + "PRIVATE_MATCH_PAGE_NEXT" "Próxima página" + + "MENU_MATCH_SETTINGS" "Configurações de partida" + "MENU_MATCH_SETTINGS_SUBMENU" "%s1 Configurações" + + "PRIVATE_MATCH_SINGLEPLAYER_LEVEL" "%s1 (Um jogador)" + + // fra hint for private match menu, because fra only has PL_fra_desc in vanilla + "PL_fra_hint" "Você está só. Mate inimigos para vencer. Colete 3 baterias para chamar um titã." + + // mode settings + "MODE_SETTING_CATEGORY_PILOT" "Piloto" + "MODE_SETTING_CATEGORY_TITAN" "Titã" + "MODE_SETTING_CATEGORY_RIFF" "Riffs" + "MODE_SETTING_CATEGORY_MATCH" "Partida" + + "classic_mp" "MP Clássico" + "run_epilogue" "Executar epílogo" + "scorelimit" "Limite de pontos" + "roundscorelimit" "Limite de pontos (por round)" + "timelimit" "Tempo limite" + "roundtimelimit" "Tempo limite (por round)" + + "pilot_health_multiplier" "Multiplicador de vida" + "respawn_delay" "Delay de reaparecimento" + "boosts_enabled" "Bônus" + "earn_meter_pilot_overdrive" "Medidor de bônus acelerado" + "earn_meter_pilot_multiplier" "Multiplicador de bônus do piloto" + + "earn_meter_titan_multiplier" "Multiplicador de bônus do titã" + "aegis_upgrades" "Upgrades Aegis" + "infinite_doomed_state" "Estado condenado infinito" + "titan_shield_regen" "Escudos regeneradores" + + "riff_floorislava" "Deadly Ground" + "featured_mode_all_holopilot" "The Great Bamboozle" + "featured_mode_all_grapple" "Attack on Titanfall" + "featured_mode_all_phase" "The Otherside" + "featured_mode_all_ticks" "Spicy" + "featured_mode_tactikill" "Tactikill" + "featured_mode_amped_tacticals" "Habilidades táticas melhoradas" + "featured_mode_rocket_arena" "Arena Foguete" + "featured_mode_shotguns_snipers" "Armado e perigoso" + "iron_rules" "Titã de ferro" + + "cp_amped_capture_points" "Pontos de captura melhorados" + "coliseum_loadouts_enabled" "Classes do Coliseu" + + // northstar.custom localisation is just deciding not to work, so putting it here for now + "PL_sbox" "Sandbox" + "PL_sbox_lobby" "Saguão de Sandbox" + "PL_sbox_desc" "gmod só que pior" + "PL_sbox_abbr" "SBOX" + "GAMEMODE_SBOX" "Sandbox" + + "PL_gg" "Gun Game" + "PL_gg_lobby" "Saguão de Gun Game" + "PL_gg_desc" "Mate com todas as armas para vencer" + "PL_gg_hint" "Mate com todas as armas para vencer" + "PL_gg_abbr" "GG" + "GAMEMODE_GG" "Gun Game" + + "PL_tt" "Titan Tag" + "PL_tt_lobby" "Saguão de Titan Tag" + "PL_tt_desc" "Ganhe pontos com seu titã. Destrua um para chamar o seu." + "PL_tt_hint" "Ganhe pontos com seu titã. Destrua um para chamar o seu." + "PL_tt_abbr" "TT" + "GAMEMODE_TT" "Titan Tag" + + "PL_inf" "Infecção" + "PL_inf_lobby" "Saguão de Infecção" + "PL_inf_desc" "Sobreviva à infecção. Sobreviventes são infectados quando mortos." + "PL_inf_hint" "Sobreviva à infecção. Sobreviventes são infectados quando mortos." + "PL_inf_abbr" "INF" + "GAMEMODE_INF" "Infecção" + "INFECTION_YOU_ARE_INFECTED" "Você foi infectado!" + "INFECTION_KILL_SURVIVORS" "Infecte todos os sobreviventes restantes." + "INFECTION_FIRST_INFECTED" "%s1 é o paciente zero." + "INFECTION_LAST_SURVIVOR" "%s1 é o último sobrevivente!" + "INFECTION_KILL_LAST_SURVIVOR" "Infecte eles antes que o tempo acabe!" + "INFECTION_YOU_ARE_LAST_SURVIVOR" "Você é o último sobrevivente!" + "INFECTION_SURVIVE_LAST_SURVIVOR" "Sobreviva." + + "PL_hs" "Esconde-esconde" + "PL_hs_lobby" "Saguão de Esconde-esconde" + "PL_hs_desc" "Jogo clássico de esconde-esconde." + "PL_hs_hint" "Jogo clássico de esconde-esconde." + "PL_hs_abbr" "HS" + "GAMEMODE_hs" "Esconde-esconde" + "HIDEANDSEEK_YOU_ARE_SEEKER" "VOCÊ PEGA!" + "HIDEANDSEEK_SEEKER_DESC" "Ache os outros e bata neles.\nVocê reaparecerá em %s1 segundos" + "HIDEANDSEEK_YOU_ARE_HIDER" "VOCÊ ESCONDE" + "HIDEANDSEEK_HIDER_DESC" "Esconda-se." + "HIDEANDSEEK_SEEKERS_INCOMING" "LÁ VEM ELES" + "HIDEANDSEEK_DONT_GET_FOUND" "Não seja encontrado!" + "HIDEANDSEEK_GET_LAST_HIDER" "%s1 É O ULTIMO ESCONDIDO" + "HIDEANDSEEK_YOU_ARE_LAST_HIDER" "VOCÊ É O ÚLTIMO ESCONDIDO" + "HIDEANDSEEK_GOT_STIM" "Você está estimulado! Não seja pego!" + "hideandseek_balance_teams" "Rebalanceamento de times" + "hideandseek_hiding_time" "Tempo escondido" + + // these are defined in r1_english but titan war is a shit name so i'm changing it to another one that was referenced in development + "GAMEMODE_fw" "Guerra pela Fronteira" + "PL_fw" "Guerra pela Fronteira" + "PL_fw_lobby" "Saguão de Guerra pela Fronteira" + "PL_fw_desc" "Destrua a colheitadeira do inimigo e proteja a sua" + "PL_fw_abbr" "FW" + + "GAMEMODE_kr" "Corrida de Matança" + "PL_kr" "Corrida de Matança" + "PL_kr_lobby" "Saguão de Matança" + "PL_kr_desc" "Acabe com inimigos para aumentar sua matança. Capture a bandeira para começar. Vença matando mais." + "PL_kr_hint" "Acabe com inimigos para aumentar sua matança. Capture a bandeira para começar. Vença matando mais." + "PL_kr_abbr" "KR" + "SCOREBOARD_KR_RECORD" "Recorde de mortes" + "KR_NEW_RACER" "%s1 é o matador" + "KR_YOU_ARE_NEW_RACER" "Você é o matador" + "KR_YOU_SET_NEW_RECORD" "Bateu o recorde!" + "KR_FLAG_INCOMING" "Bandeira reaparecerá em breve" + "KR_COLLECT_FLAG" "Capture a bandeira para virar um Matador!" + "KR_ENEMY_KILLRACE_OVER" "A matança de %s1 acabou" + "KR_YOUR_KILLRACE_OVER" "Sua matança acabou" + "KR_YOUR_KILLRACE_SCORE" "Você conseguiu %s1 mortes." + + "GAMEMODE_fastball" "Fastball" + "PL_fastball" "Fastball" + "PL_fastball_lobby" "Fastball Lobby" + "PL_fastball_desc" "Sem reaparecimento. Invada painéis de controle para ganhar rounds e reaparecer seus aliados." + "PL_fastball_hint" "Sem reaparecimento. Invada painéis de controle para ganhar rounds e reaparecer seus aliados." + "PL_fastball_abbr" "FB" + "FASTBALL_PANEL_CAPTURED" "%s1 capturou painel %s2" + "SCOREBOARD_FASTBALL_HACKS" "Painéis capturados" + + "GAMEMODE_ctf_comp" "CTF Competitivo" + + // mode settings + "MODE_SETTING_CATEGORY_PROMODE" "Modo PRO" + "MODE_SETTING_CATEGORY_BLEEDOUT" "Sangramento de piloto" + + "custom_air_accel_pilot" "Aceleração aérea" + "promode_enable" "Armas de Modo PRO" + "fp_embark_enabled" "Execuções/embarque em 1a pessoa" + "classic_rodeo" "Rodeio clássico" + "oob_timer_enabled" "Temporizador fora do mapa" + "riff_instagib" "Modo Instagib" + + "riff_player_bleedout" "Sangramento de piloto" + "player_bleedout_forceHolster" "Guardar armas ao cair" + "player_bleedout_forceDeathOnTeamBleedout" "Morrer ao time cair" + "player_bleedout_bleedoutTime" "Tempo de sangramento" + "player_bleedout_firstAidTime" "Tempo de recuperação" + "player_bleedout_firstAidTimeSelf" "Tempo de auto-recuperação" + "player_bleedout_firstAidHealPercent" "Porcentagem de vida recuperada" + "player_bleedout_aiBleedingPlayerMissChance" "Chance de erro da IA ao cair" + + // coop stuff + "PL_sp_coop" "(UNFINISHED) Singleplayer Coop" + "PL_sp_coop_lobby" "Singleplayer Coop Lobby" + "PL_sp_coop_desc" "Play through the singleplayer campaign with friends" + "PL_sp_coop_hint" "Play through the singleplayer campaign with friends" + "PL_sp_coop_abbr" "SP" + + "SP_TRAINING" "O Desafio do Piloto" + "SP_TRAINING_CLASSIC_DESC" "Simulação de treinamento do Capitão Lastimosa." + + "SP_CRASHSITE" "BT-7274" + "SP_CRASHSITE_CLASSIC_DESC" "Jack Cooper encontra BT-7274." + + "SP_SEWERS1" "Sangue e Ferrugem" + "SP_SEWERS1_CLASSIC_DESC" "Cooper e BT saem para se encontrar com Major Anderson." + + "SP_BOOMTOWN_START" "Jornada ao abismo" + "SP_BOOMTOWN_START_CLASSIC_DESC" "Um atalho debaixo da terra revela consequências inesperadas." + + "SP_HUB_TIMESHIFT" "Causa e Efeito" + "SP_HUB_TIMESHIFT_CLASSIC_DESC" "Um fenônemo não identificado é descoberto nas coordenadas do Major Anderson." + + "SP_BEACON" "O Sinalizador" + "SP_BEACON_CLASSIC_DESC" "Cooper e BT tentam informar o resto da frota sobre os planos da IMC." + + "SP_TDAY" "Prova de Fogo" + "SP_TDAY_CLASSIC_DESC" "As habilidades do tiã de Cooper são postas à prova numa batalha para capturar a Arca" + + "SP_S2S" "A Arca" + "SP_S2S_CLASSIC_DESC" "Cooper e BT vão de nave em nave em busca da Arca." + + "SP_SKYWAY_V1" "A Arma Quântica" + "SP_SKYWAY_V1_CLASSIC_DESC" "BT e Cooper são capturados por Kuben Blisk." + } +} diff --git a/Northstar.Custom/mod/resource/northstar_custom_portuguese.txt b/Northstar.Custom/mod/resource/northstar_custom_portuguese.txt new file mode 100644 index 00000000..62835f52 --- /dev/null +++ b/Northstar.Custom/mod/resource/northstar_custom_portuguese.txt @@ -0,0 +1,69 @@ +"lang" +{ + "Language" "portuguese" + "Tokens" + { + "PL_sbox" "Sandbox" + "PL_sbox_lobby" "Saguão de Sandbox" + "PL_sbox_desc" "gmod só que pior" + "PL_sbox_abbr" "SBOX" + "GAMEMODE_SBOX" "Sandbox" + + "PL_gg" "Gun Game" + "PL_gg_lobby" "Saguão de Gun Game" + "PL_gg_desc" "Mate com todas as armas para vencer" + "PL_gg_abbr" "GG" + "GAMEMODE_GG" "Gun Game" + + "PL_tt" "Titan Tag" + "PL_tt_lobby" "Saguão de Titan Tag" + "PL_tt_desc" "Ganhe pontos com seu titã. Destrua um para chamar o seu." + "PL_tt_abbr" "TT" + "GAMEMODE_TT" "Titan Tag" + + "PL_inf" "Infecção" + "PL_inf_lobby" "Saguão de Infecção" + "PL_inf_desc" "Sobreviva à infecção. Sobreviventes são infectados quando mortos." + "PL_inf_abbr" "INF" + "GAMEMODE_INF" "Infecção" + "INFECTION_YOU_ARE_INFECTED" "Você foi infectado!" + "INFECTION_KILL_SURVIVORS" "Infecte todos os sobreviventes restantes." + "INFECTION_FIRST_INFECTED" "%s1 é o paciente zero." + "INFECTION_LAST_SURVIVOR" "%s1 é o último sobrevivente!" + "INFECTION_KILL_LAST_SURVIVOR" "Infecte eles antes que o tempo acabe!" + "INFECTION_YOU_ARE_LAST_SURVIVOR" "Você é o último sobrevivente!" + "INFECTION_SURVIVE_LAST_SURVIVOR" "Sobreviva." + + // these are defined in r1_english but titan war is a shit name so i'm changing it to another one that was referenced in development + "GAMEMODE_fw" "Guerra pela Fronteira" + "PL_fw" "Guerra pela Fronteira" + "PL_fw_lobby" "Saguão de Guerra pela Fronteira" + "PL_fw_desc" "Destrua a colheitadeira do inimigo e proteja a sua" + "PL_fw_abbr" "FW" + + "GAMEMODE_kr" "Corrida de Matança" + "PL_kr" "Corrida de Matança" + "PL_kr_lobby" "Saguão de Matança" + "PL_kr_desc" "Acabe com inimigos para aumentar sua matança. Capture a bandeira para começar. Vença matando mais." + "PL_kr_abbr" "KR" + "SCOREBOARD_KR_RECORD" "Recorde de mortes" + "KR_NEW_RACER" "%s1 é o matador" + "KR_YOU_ARE_NEW_RACER" "Você é o matador" + "KR_YOU_SET_NEW_RECORD" "Bateu o recorde!" + "KR_FLAG_INCOMING" "Bandeira reaparecerá em breve" + "KR_COLLECT_FLAG" "Capture a bandeira para virar um Matador!" + "KR_ENEMY_KILLRACE_OVER" "A matança de %s1 acabou" + "KR_YOUR_KILLRACE_OVER" "Sua matança acabou" + "KR_YOUR_KILLRACE_SCORE" "Você conseguiu %s1 mortes." + + "GAMEMODE_fastball" "Fastball" + "PL_fastball" "Fastball" + "PL_fastball_lobby" "Fastball Lobby" + "PL_fastball_desc" "Sem reaparecimento. Invada painéis de controle para ganhar rounds e reaparecer seus aliados." + "PL_fastball_abbr" "FB" + "FASTBALL_PANEL_CAPTURED" "%s1 capturou painel %s2" + "SCOREBOARD_FASTBALL_HACKS" "Painéis capturados" + + "GAMEMODE_ctf_comp" "CTF Competitivo" + } +} -- cgit v1.2.3 From 0db712032a4e345513e36ac398bdafee6a8509e4 Mon Sep 17 00:00:00 2001 From: Distion55x <47297018+Distion55x@users.noreply.github.com> Date: Wed, 29 Dec 2021 15:21:56 +0100 Subject: Add files via upload --- .../northstar_client_localisation_german.txt | 216 +++++++++++++++++++++ 1 file changed, 216 insertions(+) create mode 100644 Northstar.Client/mod/resource/northstar_client_localisation_german.txt diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_german.txt b/Northstar.Client/mod/resource/northstar_client_localisation_german.txt new file mode 100644 index 00000000..fdea511e --- /dev/null +++ b/Northstar.Client/mod/resource/northstar_client_localisation_german.txt @@ -0,0 +1,216 @@ +"lang" +{ + "Language" "german" + "Tokens" + { + "MENU_LAUNCH_NORTHSTAR" "Starte Northstar" + "MENU_TITLE_MODS" "Mods" + "RELOAD_MODS" "Mods neu laden" + + "DIALOG_TITLE_INSTALLED_NORTHSTAR" "Danke, dass du Northstar installiert hast!" + "AUTHENTICATION_AGREEMENT_DIALOG_TEXT" "Damit Northstar funktionieren kann, muss es mithilfe des Northstar Masterservers authentifizieren. Dies setzt ein Weitergeben deines Origin Tokens an den Masterserver voraus, er wird nicht gespeichert oder für andere Zwecke verwendet. +Drücke Ja, um zuzustimmen. Du kannst diese Entscheidung jederzeit im Modmenü ändern." + "BACK_AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" + "AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" + "AUTHENTICATION_AGREEMENT_RESTART" "Ein Neustart ist notwendig, um diese Änderung zu übernehmen" + + "MENU_TITLE_SERVER_BROWSER" "Server Browser" + "NS_SERVERBROWSER_NOSERVERS" "Keine Server gefunden" + "NS_SERVERBROWSER_WAITINGFORSERVERS" "Warte auf Server..." + "NS_SERVERBROWSER_CONNECTIONFAILED" "Verbindung fehlgeschlagen!" + "REFRESH_SERVERS" "Neu laden" + + "MENU_TITLE_CONNECT_PASSWORD" "Verbinden mit Passwort" + "MENU_CONNECT_MENU_CONNECT" "Verbinden" + + "PRIVATE_MATCH_PAGE_PREV" "Vorherige Seite" + "PRIVATE_MATCH_PAGE_NEXT" "Nächste Seite" + + "MENU_MATCH_SETTINGS" "Match Einstellungen" + "MENU_MATCH_SETTINGS_SUBMENU" "%s1 Einstellungen" + + "PRIVATE_MATCH_SINGLEPLAYER_LEVEL" "%s1 (Einzelspieler)" + + // fra hint for private match menu, because fra only has PL_fra_desc in vanilla + "PL_fra_hint" "Du bist alleine. Töte Piloten, um zu siegen. Sammle 3 Batterien für einen Titanfall." + + // mode settings + "MODE_SETTING_CATEGORY_PILOT" "Pilot" + "MODE_SETTING_CATEGORY_TITAN" "Titan" + "MODE_SETTING_CATEGORY_RIFF" "Extras" + "MODE_SETTING_CATEGORY_MATCH" "Match" + + "classic_mp" "Klassischer Multiplayer" + "run_epilogue" "Epilog" + "scorelimit" "Höchstpunktzahl" + "roundscorelimit" "Höchstpunktzahl (rundenbasiert)" + "timelimit" "Zeitlimit" + "roundtimelimit" "Zeitlimit (rundenbasiert)" + + "pilot_health_multiplier" "HP Multiplikator" + "respawn_delay" "Respawn-Verzögerung" + "boosts_enabled" "Boosts" + "earn_meter_pilot_overdrive" "Boost-Meter overdrive" + "earn_meter_pilot_multiplier" "Piloten Boost-Meter Multiplikator" + + "earn_meter_titan_multiplier" "Titan Boost-Meter Multiplikator" + "aegis_upgrades" "Aegis Upgrades" + "infinite_doomed_state" "Unendlicher Todgeweiht-Status" + "titan_shield_regen" "Regenerierende Schilde" + + "riff_floorislava" "Tödlicher Boden" + "featured_mode_all_holopilot" "The Great Bamboozle" + "featured_mode_all_grapple" "Attack on Titanfall" + "featured_mode_all_phase" "The Otherside" + "featured_mode_all_ticks" "Scharf" + "featured_mode_tactikill" "Tactikill" + "featured_mode_amped_tacticals" "Verstärkte Tacticals" + "featured_mode_rocket_arena" "Rocket Arena" + "featured_mode_shotguns_snipers" "Bewaffnet und gefährlich" + "iron_rules" "Iron Titan Regeln" + + "cp_amped_capture_points" "Verstärkte Hardpoints" + "coliseum_loadouts_enabled" "Coliseum Loadouts" + + // northstar.custom localisation is just deciding not to work, so putting it here for now + "PL_sbox" "Sandbox" + "PL_sbox_lobby" "Sandbox Lobby" + "PL_sbox_desc" "Wie gmod, nur schlechter" + "PL_sbox_abbr" "SBOX" + "GAMEMODE_SBOX" "Sandbox" + + "PL_gg" "Gun Game" + "PL_gg_lobby" "Gun Game Lobby" + "PL_gg_desc" "Erhalte einen Kill mit jeder Waffe um zu siegen." + "PL_gg_hint" "Erhalte einen Kill mit jeder Waffe um zu siegen." + "PL_gg_abbr" "GG" + "GAMEMODE_GG" "Gun Game" + + "PL_tt" "Titan Tag" + "PL_tt_lobby" "Titan Tag Lobby" + "PL_tt_desc" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." + "PL_tt_hint" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." + "PL_tt_abbr" "TT" + "GAMEMODE_TT" "Titan Tag" + + "PL_inf" "Infektion" + "PL_inf_lobby" "Infektion-Lobby" + "PL_inf_desc" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." + "PL_inf_hint" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." + "PL_inf_abbr" "INF" + "GAMEMODE_INF" "Infektion" + "INFECTION_YOU_ARE_INFECTED" "Du wurdest infiziert!" + "INFECTION_KILL_SURVIVORS" "Töte die restlichen Überlebenden." + "INFECTION_FIRST_INFECTED" "%s1 ist der erste Infizierte." + "INFECTION_LAST_SURVIVOR" "%s1 ist der letzte Überlebende!" + "INFECTION_KILL_LAST_SURVIVOR" "Infiziere sie bevor die Zeit abläuft!" + "INFECTION_YOU_ARE_LAST_SURVIVOR" "Du bist der letzte Überlebende!" + "INFECTION_SURVIVE_LAST_SURVIVOR" "Überlebe." + + "PL_hs" "Hide and Seek" + "PL_hs_lobby" "Hide and Seek Lobby" + "PL_hs_desc" "Sucher versuchen, Versteckende zu finden." + "PL_hs_hint" "Sucher versuchen, Versteckende zu finden." + "PL_hs_abbr" "HS" + "GAMEMODE_hs" "Hide and Seek" + "HIDEANDSEEK_YOU_ARE_SEEKER" "DU BIST EIN SUCHER" + "HIDEANDSEEK_SEEKER_DESC" "Töte Versteckende mit Nahkampf.\nDu spawnst in %s1 Sekunden" + "HIDEANDSEEK_YOU_ARE_HIDER" "DU BIST VERSTECKENDER" + "HIDEANDSEEK_HIDER_DESC" "Verstecke dich vor Suchern." + "HIDEANDSEEK_SEEKERS_INCOMING" "SUCHER KOMMEN" + "HIDEANDSEEK_DONT_GET_FOUND" "Lass dich nicht finden!" + "HIDEANDSEEK_GET_LAST_HIDER" "%s1 ist der letzte Versteckende" + "HIDEANDSEEK_YOU_ARE_LAST_HIDER" "DU BIST DER LETZTE VERSTECKENDE" + "HIDEANDSEEK_GOT_STIM" "Du hast Stim! Lass dich nicht finden!" + "hideandseek_balance_teams" "Autobalance Hiders/Seekers" + "hideandseek_hiding_time" "Zeit zum Verstecken" + + // these are defined in r1_english but titan war is a shit name so i'm changing it to another one that was referenced in development + "GAMEMODE_fw" "Grenzland-Krieg" + "PL_fw" "Grenzland-Krieg" + "PL_fw_lobby" "Grenzland-Krieg Lobby" + "PL_fw_desc" "Zerstöre den feindlichen Ernter und beschütze Euren" + "PL_fw_abbr" "GK" + + "GAMEMODE_kr" "Verstärktes Killrace" + "PL_kr" "Verstärktes Killrace" + "PL_kr_lobby" "Verstärktes Killrace Lobby" + "PL_kr_desc" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." + "PL_kr_hint" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." + "PL_kr_abbr" "KR" + "SCOREBOARD_KR_RECORD" "Kill-Rekord" + "KR_NEW_RACER" "%s1 ist der Killracer" + "KR_YOU_ARE_NEW_RACER" "Du bist der Killracer" + "KR_YOU_SET_NEW_RECORD" "Setze einen neuen Kill-Rekord!" + "KR_FLAG_INCOMING" "Fahne erscheint" + "KR_COLLECT_FLAG" "Sammle sie ein um zum Killracer zu werden!" + "KR_ENEMY_KILLRACE_OVER" "%s1's Killstreak ist vorbei" + "KR_YOUR_KILLRACE_OVER" "Deine Killstreak ist vorbei" + "KR_YOUR_KILLRACE_SCORE" "Du hast %s1 Kills." + + "GAMEMODE_fastball" "Fastball" + "PL_fastball" "Fastball" + "PL_fastball_lobby" "Fastball Lobby" + "PL_fastball_desc" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." + "PL_fastball_hint" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." + "PL_fastball_abbr" "FB" + "FASTBALL_PANEL_CAPTURED" "%s1 eroberte Konsole %s2" + "SCOREBOARD_FASTBALL_HACKS" "Konsolen erobert" + + "GAMEMODE_ctf_comp" "Competitive CTF" + + // mode settings + "MODE_SETTING_CATEGORY_PROMODE" "Pro-Modus" + "MODE_SETTING_CATEGORY_BLEEDOUT" "Pilot Bleedout" + + "custom_air_accel_pilot" "Luftbeschleunigung" + "promode_enable" "Pro-mode Waffen" + "fp_embark_enabled" "Firstperson Einstiege/Exekutionen" + "classic_rodeo" "Klassisches Rodeo" + "oob_timer_enabled" "Out of Bounds Timer" + "riff_instagib" "Instagib Mode" + + "riff_player_bleedout" "Piloten Bleedout" + "player_bleedout_forceHolster" "Waffen während Ausgeschaltet wegstecken" + "player_bleedout_forceDeathOnTeamBleedout" "Stirb bei Team Bleedout" + "player_bleedout_bleedoutTime" "Bleedout Zeit" + "player_bleedout_firstAidTime" "Erste Hilfe Zeit" + "player_bleedout_firstAidTimeSelf" "Self-res time" + "player_bleedout_firstAidHealPercent" "Erste Hilfe HP Prozent" + "player_bleedout_aiBleedingPlayerMissChance" "Ausgeschaltet AI Verfehl-Chance" + + // coop stuff + "PL_sp_coop" "(UNFINISHED) Kampagne Koop" + "PL_sp_coop_lobby" "Kampagne Koop Lobby" + "PL_sp_coop_desc" "Spiele mit Freuden durch die Einzelspieler-Kampagne" + "PL_sp_coop_hint" "Spiele mit Freuden durch die Einzelspieler-Kampagne" + "PL_sp_coop_abbr" "SP" + + "SP_TRAINING" "Der Piloten-Parkour" + "SP_TRAINING_CLASSIC_DESC" "Captain Lastimosas Trainingssimulation." + + "SP_CRASHSITE" "BT-7274" + "SP_CRASHSITE_CLASSIC_DESC" "Jack Cooper trifft BT-7274." + + "SP_SEWERS1" "Blut und Rost" + "SP_SEWERS1_CLASSIC_DESC" "Cooper und BT machen sich auf den Weg zum Treffpunkt mit Major Anderson." + + "SP_BOOMTOWN_START" "In den Abgrund" + "SP_BOOMTOWN_START_CLASSIC_DESC" "Eine unterirdische Abkürzung zieht unerwartete Konsequenzen mit sich." + + "SP_HUB_TIMESHIFT" "Wirkung und Ursache" + "SP_HUB_TIMESHIFT_CLASSIC_DESC" "An Major Andersons Koordinaten trifft ein seltsames Phänomen auf." + + "SP_BEACON" "Der Sender" + "SP_BEACON_CLASSIC_DESC" "Cooper und BT versuchen, die Restflotte über die Pläne der IMC zu informieren." + + "SP_TDAY" "Feuerprobe" + "SP_TDAY_CLASSIC_DESC" "Coopers Titan-Fähigkeiten werden im Kampf um die Lade auf eine harte Probe gestellt" + + "SP_S2S" "Die Lade" + "SP_S2S_CLASSIC_DESC" "Cooper und BT gehen von Schiff zu Schiff, um die Lade zu finden." + + "SP_SKYWAY_V1" "Die Faltwaffe" + "SP_SKYWAY_V1_CLASSIC_DESC" "BT und Cooper werden von Kuben Blist gefangen genommen." + } +} -- cgit v1.2.3 From ef2615f9408a7ed5cafa4d070f581954372360e9 Mon Sep 17 00:00:00 2001 From: Distion55x <47297018+Distion55x@users.noreply.github.com> Date: Wed, 29 Dec 2021 15:23:10 +0100 Subject: Delete northstar_client_localisation_german.txt --- .../northstar_client_localisation_german.txt | 216 --------------------- 1 file changed, 216 deletions(-) delete mode 100644 Northstar.Client/mod/resource/northstar_client_localisation_german.txt diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_german.txt b/Northstar.Client/mod/resource/northstar_client_localisation_german.txt deleted file mode 100644 index fdea511e..00000000 --- a/Northstar.Client/mod/resource/northstar_client_localisation_german.txt +++ /dev/null @@ -1,216 +0,0 @@ -"lang" -{ - "Language" "german" - "Tokens" - { - "MENU_LAUNCH_NORTHSTAR" "Starte Northstar" - "MENU_TITLE_MODS" "Mods" - "RELOAD_MODS" "Mods neu laden" - - "DIALOG_TITLE_INSTALLED_NORTHSTAR" "Danke, dass du Northstar installiert hast!" - "AUTHENTICATION_AGREEMENT_DIALOG_TEXT" "Damit Northstar funktionieren kann, muss es mithilfe des Northstar Masterservers authentifizieren. Dies setzt ein Weitergeben deines Origin Tokens an den Masterserver voraus, er wird nicht gespeichert oder für andere Zwecke verwendet. -Drücke Ja, um zuzustimmen. Du kannst diese Entscheidung jederzeit im Modmenü ändern." - "BACK_AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" - "AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" - "AUTHENTICATION_AGREEMENT_RESTART" "Ein Neustart ist notwendig, um diese Änderung zu übernehmen" - - "MENU_TITLE_SERVER_BROWSER" "Server Browser" - "NS_SERVERBROWSER_NOSERVERS" "Keine Server gefunden" - "NS_SERVERBROWSER_WAITINGFORSERVERS" "Warte auf Server..." - "NS_SERVERBROWSER_CONNECTIONFAILED" "Verbindung fehlgeschlagen!" - "REFRESH_SERVERS" "Neu laden" - - "MENU_TITLE_CONNECT_PASSWORD" "Verbinden mit Passwort" - "MENU_CONNECT_MENU_CONNECT" "Verbinden" - - "PRIVATE_MATCH_PAGE_PREV" "Vorherige Seite" - "PRIVATE_MATCH_PAGE_NEXT" "Nächste Seite" - - "MENU_MATCH_SETTINGS" "Match Einstellungen" - "MENU_MATCH_SETTINGS_SUBMENU" "%s1 Einstellungen" - - "PRIVATE_MATCH_SINGLEPLAYER_LEVEL" "%s1 (Einzelspieler)" - - // fra hint for private match menu, because fra only has PL_fra_desc in vanilla - "PL_fra_hint" "Du bist alleine. Töte Piloten, um zu siegen. Sammle 3 Batterien für einen Titanfall." - - // mode settings - "MODE_SETTING_CATEGORY_PILOT" "Pilot" - "MODE_SETTING_CATEGORY_TITAN" "Titan" - "MODE_SETTING_CATEGORY_RIFF" "Extras" - "MODE_SETTING_CATEGORY_MATCH" "Match" - - "classic_mp" "Klassischer Multiplayer" - "run_epilogue" "Epilog" - "scorelimit" "Höchstpunktzahl" - "roundscorelimit" "Höchstpunktzahl (rundenbasiert)" - "timelimit" "Zeitlimit" - "roundtimelimit" "Zeitlimit (rundenbasiert)" - - "pilot_health_multiplier" "HP Multiplikator" - "respawn_delay" "Respawn-Verzögerung" - "boosts_enabled" "Boosts" - "earn_meter_pilot_overdrive" "Boost-Meter overdrive" - "earn_meter_pilot_multiplier" "Piloten Boost-Meter Multiplikator" - - "earn_meter_titan_multiplier" "Titan Boost-Meter Multiplikator" - "aegis_upgrades" "Aegis Upgrades" - "infinite_doomed_state" "Unendlicher Todgeweiht-Status" - "titan_shield_regen" "Regenerierende Schilde" - - "riff_floorislava" "Tödlicher Boden" - "featured_mode_all_holopilot" "The Great Bamboozle" - "featured_mode_all_grapple" "Attack on Titanfall" - "featured_mode_all_phase" "The Otherside" - "featured_mode_all_ticks" "Scharf" - "featured_mode_tactikill" "Tactikill" - "featured_mode_amped_tacticals" "Verstärkte Tacticals" - "featured_mode_rocket_arena" "Rocket Arena" - "featured_mode_shotguns_snipers" "Bewaffnet und gefährlich" - "iron_rules" "Iron Titan Regeln" - - "cp_amped_capture_points" "Verstärkte Hardpoints" - "coliseum_loadouts_enabled" "Coliseum Loadouts" - - // northstar.custom localisation is just deciding not to work, so putting it here for now - "PL_sbox" "Sandbox" - "PL_sbox_lobby" "Sandbox Lobby" - "PL_sbox_desc" "Wie gmod, nur schlechter" - "PL_sbox_abbr" "SBOX" - "GAMEMODE_SBOX" "Sandbox" - - "PL_gg" "Gun Game" - "PL_gg_lobby" "Gun Game Lobby" - "PL_gg_desc" "Erhalte einen Kill mit jeder Waffe um zu siegen." - "PL_gg_hint" "Erhalte einen Kill mit jeder Waffe um zu siegen." - "PL_gg_abbr" "GG" - "GAMEMODE_GG" "Gun Game" - - "PL_tt" "Titan Tag" - "PL_tt_lobby" "Titan Tag Lobby" - "PL_tt_desc" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." - "PL_tt_hint" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." - "PL_tt_abbr" "TT" - "GAMEMODE_TT" "Titan Tag" - - "PL_inf" "Infektion" - "PL_inf_lobby" "Infektion-Lobby" - "PL_inf_desc" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." - "PL_inf_hint" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." - "PL_inf_abbr" "INF" - "GAMEMODE_INF" "Infektion" - "INFECTION_YOU_ARE_INFECTED" "Du wurdest infiziert!" - "INFECTION_KILL_SURVIVORS" "Töte die restlichen Überlebenden." - "INFECTION_FIRST_INFECTED" "%s1 ist der erste Infizierte." - "INFECTION_LAST_SURVIVOR" "%s1 ist der letzte Überlebende!" - "INFECTION_KILL_LAST_SURVIVOR" "Infiziere sie bevor die Zeit abläuft!" - "INFECTION_YOU_ARE_LAST_SURVIVOR" "Du bist der letzte Überlebende!" - "INFECTION_SURVIVE_LAST_SURVIVOR" "Überlebe." - - "PL_hs" "Hide and Seek" - "PL_hs_lobby" "Hide and Seek Lobby" - "PL_hs_desc" "Sucher versuchen, Versteckende zu finden." - "PL_hs_hint" "Sucher versuchen, Versteckende zu finden." - "PL_hs_abbr" "HS" - "GAMEMODE_hs" "Hide and Seek" - "HIDEANDSEEK_YOU_ARE_SEEKER" "DU BIST EIN SUCHER" - "HIDEANDSEEK_SEEKER_DESC" "Töte Versteckende mit Nahkampf.\nDu spawnst in %s1 Sekunden" - "HIDEANDSEEK_YOU_ARE_HIDER" "DU BIST VERSTECKENDER" - "HIDEANDSEEK_HIDER_DESC" "Verstecke dich vor Suchern." - "HIDEANDSEEK_SEEKERS_INCOMING" "SUCHER KOMMEN" - "HIDEANDSEEK_DONT_GET_FOUND" "Lass dich nicht finden!" - "HIDEANDSEEK_GET_LAST_HIDER" "%s1 ist der letzte Versteckende" - "HIDEANDSEEK_YOU_ARE_LAST_HIDER" "DU BIST DER LETZTE VERSTECKENDE" - "HIDEANDSEEK_GOT_STIM" "Du hast Stim! Lass dich nicht finden!" - "hideandseek_balance_teams" "Autobalance Hiders/Seekers" - "hideandseek_hiding_time" "Zeit zum Verstecken" - - // these are defined in r1_english but titan war is a shit name so i'm changing it to another one that was referenced in development - "GAMEMODE_fw" "Grenzland-Krieg" - "PL_fw" "Grenzland-Krieg" - "PL_fw_lobby" "Grenzland-Krieg Lobby" - "PL_fw_desc" "Zerstöre den feindlichen Ernter und beschütze Euren" - "PL_fw_abbr" "GK" - - "GAMEMODE_kr" "Verstärktes Killrace" - "PL_kr" "Verstärktes Killrace" - "PL_kr_lobby" "Verstärktes Killrace Lobby" - "PL_kr_desc" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." - "PL_kr_hint" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." - "PL_kr_abbr" "KR" - "SCOREBOARD_KR_RECORD" "Kill-Rekord" - "KR_NEW_RACER" "%s1 ist der Killracer" - "KR_YOU_ARE_NEW_RACER" "Du bist der Killracer" - "KR_YOU_SET_NEW_RECORD" "Setze einen neuen Kill-Rekord!" - "KR_FLAG_INCOMING" "Fahne erscheint" - "KR_COLLECT_FLAG" "Sammle sie ein um zum Killracer zu werden!" - "KR_ENEMY_KILLRACE_OVER" "%s1's Killstreak ist vorbei" - "KR_YOUR_KILLRACE_OVER" "Deine Killstreak ist vorbei" - "KR_YOUR_KILLRACE_SCORE" "Du hast %s1 Kills." - - "GAMEMODE_fastball" "Fastball" - "PL_fastball" "Fastball" - "PL_fastball_lobby" "Fastball Lobby" - "PL_fastball_desc" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." - "PL_fastball_hint" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." - "PL_fastball_abbr" "FB" - "FASTBALL_PANEL_CAPTURED" "%s1 eroberte Konsole %s2" - "SCOREBOARD_FASTBALL_HACKS" "Konsolen erobert" - - "GAMEMODE_ctf_comp" "Competitive CTF" - - // mode settings - "MODE_SETTING_CATEGORY_PROMODE" "Pro-Modus" - "MODE_SETTING_CATEGORY_BLEEDOUT" "Pilot Bleedout" - - "custom_air_accel_pilot" "Luftbeschleunigung" - "promode_enable" "Pro-mode Waffen" - "fp_embark_enabled" "Firstperson Einstiege/Exekutionen" - "classic_rodeo" "Klassisches Rodeo" - "oob_timer_enabled" "Out of Bounds Timer" - "riff_instagib" "Instagib Mode" - - "riff_player_bleedout" "Piloten Bleedout" - "player_bleedout_forceHolster" "Waffen während Ausgeschaltet wegstecken" - "player_bleedout_forceDeathOnTeamBleedout" "Stirb bei Team Bleedout" - "player_bleedout_bleedoutTime" "Bleedout Zeit" - "player_bleedout_firstAidTime" "Erste Hilfe Zeit" - "player_bleedout_firstAidTimeSelf" "Self-res time" - "player_bleedout_firstAidHealPercent" "Erste Hilfe HP Prozent" - "player_bleedout_aiBleedingPlayerMissChance" "Ausgeschaltet AI Verfehl-Chance" - - // coop stuff - "PL_sp_coop" "(UNFINISHED) Kampagne Koop" - "PL_sp_coop_lobby" "Kampagne Koop Lobby" - "PL_sp_coop_desc" "Spiele mit Freuden durch die Einzelspieler-Kampagne" - "PL_sp_coop_hint" "Spiele mit Freuden durch die Einzelspieler-Kampagne" - "PL_sp_coop_abbr" "SP" - - "SP_TRAINING" "Der Piloten-Parkour" - "SP_TRAINING_CLASSIC_DESC" "Captain Lastimosas Trainingssimulation." - - "SP_CRASHSITE" "BT-7274" - "SP_CRASHSITE_CLASSIC_DESC" "Jack Cooper trifft BT-7274." - - "SP_SEWERS1" "Blut und Rost" - "SP_SEWERS1_CLASSIC_DESC" "Cooper und BT machen sich auf den Weg zum Treffpunkt mit Major Anderson." - - "SP_BOOMTOWN_START" "In den Abgrund" - "SP_BOOMTOWN_START_CLASSIC_DESC" "Eine unterirdische Abkürzung zieht unerwartete Konsequenzen mit sich." - - "SP_HUB_TIMESHIFT" "Wirkung und Ursache" - "SP_HUB_TIMESHIFT_CLASSIC_DESC" "An Major Andersons Koordinaten trifft ein seltsames Phänomen auf." - - "SP_BEACON" "Der Sender" - "SP_BEACON_CLASSIC_DESC" "Cooper und BT versuchen, die Restflotte über die Pläne der IMC zu informieren." - - "SP_TDAY" "Feuerprobe" - "SP_TDAY_CLASSIC_DESC" "Coopers Titan-Fähigkeiten werden im Kampf um die Lade auf eine harte Probe gestellt" - - "SP_S2S" "Die Lade" - "SP_S2S_CLASSIC_DESC" "Cooper und BT gehen von Schiff zu Schiff, um die Lade zu finden." - - "SP_SKYWAY_V1" "Die Faltwaffe" - "SP_SKYWAY_V1_CLASSIC_DESC" "BT und Cooper werden von Kuben Blist gefangen genommen." - } -} -- cgit v1.2.3 From 7fdfaf24d2bc78d1ba80fe0111b0aa1af0f7dd93 Mon Sep 17 00:00:00 2001 From: Distion55x <47297018+Distion55x@users.noreply.github.com> Date: Wed, 29 Dec 2021 15:27:02 +0100 Subject: Add northstar_client_localisation_german.txt Added a German translation for the Northstar Client --- .../northstar_client_localisation_german.txt | 216 +++++++++++++++++++++ 1 file changed, 216 insertions(+) create mode 100644 Northstar.Client/mod/resource/northstar_client_localisation_german.txt diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_german.txt b/Northstar.Client/mod/resource/northstar_client_localisation_german.txt new file mode 100644 index 00000000..fdea511e --- /dev/null +++ b/Northstar.Client/mod/resource/northstar_client_localisation_german.txt @@ -0,0 +1,216 @@ +"lang" +{ + "Language" "german" + "Tokens" + { + "MENU_LAUNCH_NORTHSTAR" "Starte Northstar" + "MENU_TITLE_MODS" "Mods" + "RELOAD_MODS" "Mods neu laden" + + "DIALOG_TITLE_INSTALLED_NORTHSTAR" "Danke, dass du Northstar installiert hast!" + "AUTHENTICATION_AGREEMENT_DIALOG_TEXT" "Damit Northstar funktionieren kann, muss es mithilfe des Northstar Masterservers authentifizieren. Dies setzt ein Weitergeben deines Origin Tokens an den Masterserver voraus, er wird nicht gespeichert oder für andere Zwecke verwendet. +Drücke Ja, um zuzustimmen. Du kannst diese Entscheidung jederzeit im Modmenü ändern." + "BACK_AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" + "AUTHENTICATION_AGREEMENT" "Authentifizierungs-Einwilligung" + "AUTHENTICATION_AGREEMENT_RESTART" "Ein Neustart ist notwendig, um diese Änderung zu übernehmen" + + "MENU_TITLE_SERVER_BROWSER" "Server Browser" + "NS_SERVERBROWSER_NOSERVERS" "Keine Server gefunden" + "NS_SERVERBROWSER_WAITINGFORSERVERS" "Warte auf Server..." + "NS_SERVERBROWSER_CONNECTIONFAILED" "Verbindung fehlgeschlagen!" + "REFRESH_SERVERS" "Neu laden" + + "MENU_TITLE_CONNECT_PASSWORD" "Verbinden mit Passwort" + "MENU_CONNECT_MENU_CONNECT" "Verbinden" + + "PRIVATE_MATCH_PAGE_PREV" "Vorherige Seite" + "PRIVATE_MATCH_PAGE_NEXT" "Nächste Seite" + + "MENU_MATCH_SETTINGS" "Match Einstellungen" + "MENU_MATCH_SETTINGS_SUBMENU" "%s1 Einstellungen" + + "PRIVATE_MATCH_SINGLEPLAYER_LEVEL" "%s1 (Einzelspieler)" + + // fra hint for private match menu, because fra only has PL_fra_desc in vanilla + "PL_fra_hint" "Du bist alleine. Töte Piloten, um zu siegen. Sammle 3 Batterien für einen Titanfall." + + // mode settings + "MODE_SETTING_CATEGORY_PILOT" "Pilot" + "MODE_SETTING_CATEGORY_TITAN" "Titan" + "MODE_SETTING_CATEGORY_RIFF" "Extras" + "MODE_SETTING_CATEGORY_MATCH" "Match" + + "classic_mp" "Klassischer Multiplayer" + "run_epilogue" "Epilog" + "scorelimit" "Höchstpunktzahl" + "roundscorelimit" "Höchstpunktzahl (rundenbasiert)" + "timelimit" "Zeitlimit" + "roundtimelimit" "Zeitlimit (rundenbasiert)" + + "pilot_health_multiplier" "HP Multiplikator" + "respawn_delay" "Respawn-Verzögerung" + "boosts_enabled" "Boosts" + "earn_meter_pilot_overdrive" "Boost-Meter overdrive" + "earn_meter_pilot_multiplier" "Piloten Boost-Meter Multiplikator" + + "earn_meter_titan_multiplier" "Titan Boost-Meter Multiplikator" + "aegis_upgrades" "Aegis Upgrades" + "infinite_doomed_state" "Unendlicher Todgeweiht-Status" + "titan_shield_regen" "Regenerierende Schilde" + + "riff_floorislava" "Tödlicher Boden" + "featured_mode_all_holopilot" "The Great Bamboozle" + "featured_mode_all_grapple" "Attack on Titanfall" + "featured_mode_all_phase" "The Otherside" + "featured_mode_all_ticks" "Scharf" + "featured_mode_tactikill" "Tactikill" + "featured_mode_amped_tacticals" "Verstärkte Tacticals" + "featured_mode_rocket_arena" "Rocket Arena" + "featured_mode_shotguns_snipers" "Bewaffnet und gefährlich" + "iron_rules" "Iron Titan Regeln" + + "cp_amped_capture_points" "Verstärkte Hardpoints" + "coliseum_loadouts_enabled" "Coliseum Loadouts" + + // northstar.custom localisation is just deciding not to work, so putting it here for now + "PL_sbox" "Sandbox" + "PL_sbox_lobby" "Sandbox Lobby" + "PL_sbox_desc" "Wie gmod, nur schlechter" + "PL_sbox_abbr" "SBOX" + "GAMEMODE_SBOX" "Sandbox" + + "PL_gg" "Gun Game" + "PL_gg_lobby" "Gun Game Lobby" + "PL_gg_desc" "Erhalte einen Kill mit jeder Waffe um zu siegen." + "PL_gg_hint" "Erhalte einen Kill mit jeder Waffe um zu siegen." + "PL_gg_abbr" "GG" + "GAMEMODE_GG" "Gun Game" + + "PL_tt" "Titan Tag" + "PL_tt_lobby" "Titan Tag Lobby" + "PL_tt_desc" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." + "PL_tt_hint" "Erringe Punkte in deinem Titan. Zerstöre einen Titan für deinen Eigenen." + "PL_tt_abbr" "TT" + "GAMEMODE_TT" "Titan Tag" + + "PL_inf" "Infektion" + "PL_inf_lobby" "Infektion-Lobby" + "PL_inf_desc" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." + "PL_inf_hint" "Überlebe die Infektion. Überlebende werden nach dem Tod infiziert." + "PL_inf_abbr" "INF" + "GAMEMODE_INF" "Infektion" + "INFECTION_YOU_ARE_INFECTED" "Du wurdest infiziert!" + "INFECTION_KILL_SURVIVORS" "Töte die restlichen Überlebenden." + "INFECTION_FIRST_INFECTED" "%s1 ist der erste Infizierte." + "INFECTION_LAST_SURVIVOR" "%s1 ist der letzte Überlebende!" + "INFECTION_KILL_LAST_SURVIVOR" "Infiziere sie bevor die Zeit abläuft!" + "INFECTION_YOU_ARE_LAST_SURVIVOR" "Du bist der letzte Überlebende!" + "INFECTION_SURVIVE_LAST_SURVIVOR" "Überlebe." + + "PL_hs" "Hide and Seek" + "PL_hs_lobby" "Hide and Seek Lobby" + "PL_hs_desc" "Sucher versuchen, Versteckende zu finden." + "PL_hs_hint" "Sucher versuchen, Versteckende zu finden." + "PL_hs_abbr" "HS" + "GAMEMODE_hs" "Hide and Seek" + "HIDEANDSEEK_YOU_ARE_SEEKER" "DU BIST EIN SUCHER" + "HIDEANDSEEK_SEEKER_DESC" "Töte Versteckende mit Nahkampf.\nDu spawnst in %s1 Sekunden" + "HIDEANDSEEK_YOU_ARE_HIDER" "DU BIST VERSTECKENDER" + "HIDEANDSEEK_HIDER_DESC" "Verstecke dich vor Suchern." + "HIDEANDSEEK_SEEKERS_INCOMING" "SUCHER KOMMEN" + "HIDEANDSEEK_DONT_GET_FOUND" "Lass dich nicht finden!" + "HIDEANDSEEK_GET_LAST_HIDER" "%s1 ist der letzte Versteckende" + "HIDEANDSEEK_YOU_ARE_LAST_HIDER" "DU BIST DER LETZTE VERSTECKENDE" + "HIDEANDSEEK_GOT_STIM" "Du hast Stim! Lass dich nicht finden!" + "hideandseek_balance_teams" "Autobalance Hiders/Seekers" + "hideandseek_hiding_time" "Zeit zum Verstecken" + + // these are defined in r1_english but titan war is a shit name so i'm changing it to another one that was referenced in development + "GAMEMODE_fw" "Grenzland-Krieg" + "PL_fw" "Grenzland-Krieg" + "PL_fw_lobby" "Grenzland-Krieg Lobby" + "PL_fw_desc" "Zerstöre den feindlichen Ernter und beschütze Euren" + "PL_fw_abbr" "GK" + + "GAMEMODE_kr" "Verstärktes Killrace" + "PL_kr" "Verstärktes Killrace" + "PL_kr_lobby" "Verstärktes Killrace Lobby" + "PL_kr_desc" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." + "PL_kr_hint" "Töte Piloten um die Länge deiner Killstreak zu erhöhen. Sammle die Fahne ein, um sie zu starten. Setze den Rekord, um zu gewinnen." + "PL_kr_abbr" "KR" + "SCOREBOARD_KR_RECORD" "Kill-Rekord" + "KR_NEW_RACER" "%s1 ist der Killracer" + "KR_YOU_ARE_NEW_RACER" "Du bist der Killracer" + "KR_YOU_SET_NEW_RECORD" "Setze einen neuen Kill-Rekord!" + "KR_FLAG_INCOMING" "Fahne erscheint" + "KR_COLLECT_FLAG" "Sammle sie ein um zum Killracer zu werden!" + "KR_ENEMY_KILLRACE_OVER" "%s1's Killstreak ist vorbei" + "KR_YOUR_KILLRACE_OVER" "Deine Killstreak ist vorbei" + "KR_YOUR_KILLRACE_SCORE" "Du hast %s1 Kills." + + "GAMEMODE_fastball" "Fastball" + "PL_fastball" "Fastball" + "PL_fastball_lobby" "Fastball Lobby" + "PL_fastball_desc" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." + "PL_fastball_hint" "Permatod. Häcke Kontrollkonsolen um Punkte zu gewinnen und deine Kameraden zurückzuholen." + "PL_fastball_abbr" "FB" + "FASTBALL_PANEL_CAPTURED" "%s1 eroberte Konsole %s2" + "SCOREBOARD_FASTBALL_HACKS" "Konsolen erobert" + + "GAMEMODE_ctf_comp" "Competitive CTF" + + // mode settings + "MODE_SETTING_CATEGORY_PROMODE" "Pro-Modus" + "MODE_SETTING_CATEGORY_BLEEDOUT" "Pilot Bleedout" + + "custom_air_accel_pilot" "Luftbeschleunigung" + "promode_enable" "Pro-mode Waffen" + "fp_embark_enabled" "Firstperson Einstiege/Exekutionen" + "classic_rodeo" "Klassisches Rodeo" + "oob_timer_enabled" "Out of Bounds Timer" + "riff_instagib" "Instagib Mode" + + "riff_player_bleedout" "Piloten Bleedout" + "player_bleedout_forceHolster" "Waffen während Ausgeschaltet wegstecken" + "player_bleedout_forceDeathOnTeamBleedout" "Stirb bei Team Bleedout" + "player_bleedout_bleedoutTime" "Bleedout Zeit" + "player_bleedout_firstAidTime" "Erste Hilfe Zeit" + "player_bleedout_firstAidTimeSelf" "Self-res time" + "player_bleedout_firstAidHealPercent" "Erste Hilfe HP Prozent" + "player_bleedout_aiBleedingPlayerMissChance" "Ausgeschaltet AI Verfehl-Chance" + + // coop stuff + "PL_sp_coop" "(UNFINISHED) Kampagne Koop" + "PL_sp_coop_lobby" "Kampagne Koop Lobby" + "PL_sp_coop_desc" "Spiele mit Freuden durch die Einzelspieler-Kampagne" + "PL_sp_coop_hint" "Spiele mit Freuden durch die Einzelspieler-Kampagne" + "PL_sp_coop_abbr" "SP" + + "SP_TRAINING" "Der Piloten-Parkour" + "SP_TRAINING_CLASSIC_DESC" "Captain Lastimosas Trainingssimulation." + + "SP_CRASHSITE" "BT-7274" + "SP_CRASHSITE_CLASSIC_DESC" "Jack Cooper trifft BT-7274." + + "SP_SEWERS1" "Blut und Rost" + "SP_SEWERS1_CLASSIC_DESC" "Cooper und BT machen sich auf den Weg zum Treffpunkt mit Major Anderson." + + "SP_BOOMTOWN_START" "In den Abgrund" + "SP_BOOMTOWN_START_CLASSIC_DESC" "Eine unterirdische Abkürzung zieht unerwartete Konsequenzen mit sich." + + "SP_HUB_TIMESHIFT" "Wirkung und Ursache" + "SP_HUB_TIMESHIFT_CLASSIC_DESC" "An Major Andersons Koordinaten trifft ein seltsames Phänomen auf." + + "SP_BEACON" "Der Sender" + "SP_BEACON_CLASSIC_DESC" "Cooper und BT versuchen, die Restflotte über die Pläne der IMC zu informieren." + + "SP_TDAY" "Feuerprobe" + "SP_TDAY_CLASSIC_DESC" "Coopers Titan-Fähigkeiten werden im Kampf um die Lade auf eine harte Probe gestellt" + + "SP_S2S" "Die Lade" + "SP_S2S_CLASSIC_DESC" "Cooper und BT gehen von Schiff zu Schiff, um die Lade zu finden." + + "SP_SKYWAY_V1" "Die Faltwaffe" + "SP_SKYWAY_V1_CLASSIC_DESC" "BT und Cooper werden von Kuben Blist gefangen genommen." + } +} -- cgit v1.2.3 From 695fa2cf1e4cb5420772e061b22eb18f0ac8cba1 Mon Sep 17 00:00:00 2001 From: Anreol <12176932+Anreol@users.noreply.github.com> Date: Wed, 29 Dec 2021 17:03:11 +0100 Subject: Add files via upload --- .../resource/northstar_client_localisation_spanish.txt | Bin 0 -> 20430 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Northstar.Client/mod/resource/northstar_client_localisation_spanish.txt diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_spanish.txt b/Northstar.Client/mod/resource/northstar_client_localisation_spanish.txt new file mode 100644 index 00000000..86f57a41 Binary files /dev/null and b/Northstar.Client/mod/resource/northstar_client_localisation_spanish.txt differ -- cgit v1.2.3 From e888cfd48b7184821fb4f9eac84cfa952e55a6f8 Mon Sep 17 00:00:00 2001 From: F1F7Y Date: Thu, 30 Dec 2021 00:12:09 +0100 Subject: Commit Better.serverbrowser --- Northstar.Client/mod.json | 23 +- .../northstar_client_localisation_english.txt | Bin 18414 -> 20042 bytes .../mod/resource/ui/menus/server_browser.menu | 2321 +++++++++++++++++++- .../mod/scripts/vscripts/sh_menu_models.gnut | 6 +- .../scripts/vscripts/ui/menu_ns_serverbrowser.nut | 1124 ++++++++-- 5 files changed, 3299 insertions(+), 175 deletions(-) diff --git a/Northstar.Client/mod.json b/Northstar.Client/mod.json index ac1e0951..4842755b 100644 --- a/Northstar.Client/mod.json +++ b/Northstar.Client/mod.json @@ -3,7 +3,28 @@ "Description" : "Various ui and client changes to fix bugs and add better support for mods", "Version": "1.0.0", "LoadPriority": 0, - + "ConVars": [ + { + "Name": "filter_hide_empty", + "DefaultValue": "0" + }, + { + "Name": "filter_hide_full", + "DefaultValue": "0" + }, + { + "Name": "filter_hide_protected", + "DefaultValue": "0" + }, + { + "Name": "filter_map", + "DefaultValue": "0" + }, + { + "Name": "filter_gamemode", + "DefaultValue": "0" + } + ], // ui inits need to happen before so our init callbacks get called "Scripts": [ { diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_english.txt b/Northstar.Client/mod/resource/northstar_client_localisation_english.txt index a0a8026e..b37afef3 100644 Binary files a/Northstar.Client/mod/resource/northstar_client_localisation_english.txt and b/Northstar.Client/mod/resource/northstar_client_localisation_english.txt differ diff --git a/Northstar.Client/mod/resource/ui/menus/server_browser.menu b/Northstar.Client/mod/resource/ui/menus/server_browser.menu index 213f46e9..b67a2918 100644 --- a/Northstar.Client/mod/resource/ui/menus/server_browser.menu +++ b/Northstar.Client/mod/resource/ui/menus/server_browser.menu @@ -34,45 +34,1744 @@ resource/ui/menus/mods_browse.menu ControlName ImagePanel InheritProperties MenuTopBar } - + ButtonRowAnchor { ControlName Label labelText "" - xpos 120 - ypos 160 + xpos 130 + ypos 204 + } + + RowButtonsAnchor + { + ControlName Label + labelText "" + + xpos 94 + ypos 160 + } + + FilterButtonsRowAnchor + { + ControlName Label + labelText "" + + xpos 90 + ypos 807 + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + DarkenBackground + { + ControlName Label + classname ConnectingHUD + xpos 0 + ypos 0 + zpos 99 + wide %100 + tall %100 + labelText "" + bgcolor_override "0 0 0 160" + visible 1 + paintbackground 1 + } + + ConnectingAnimation + { + ControlName RuiPanel + classname ConnectingHUD + rui "ui/matchmaking_status_big.rpak" + + xpos 448 + ypos 284 + wide 1024 + tall 512 + + zpos 100 + visible 1 + } + + + + ConnectingLabel + { + ControlName Label + classname ConnectingHUD + wide 160 + tall 40 + ypos -310 + xpos -432 + labelText "#CONNECTING" + fgcolor_override "107 166 196 255" + textAlignment center + + visible 1 + zpos 101 + + pin_to_sibling ConnectingAnimation + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + ConnectingLabelBackground + { + ControlName RuiPanel + classname ConnectingHUD + wide 160 + tall 40 + ypos -310 + xpos -432 + zpos 100 + + rui "ui/knowledgebase_panel.rpak" + + pin_to_sibling ConnectingAnimation + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + ConnectingButton + { + ControlName RuiButton + classname ConnectingHUD + InheritProperties RuiSmallButton + labelText "#CANCEL" + textAlignment center + wide 100 + tall 40 + ypos -220 + xpos -462 + zpos 101 + + //fgcolor_override "107 166 196 255" + + pin_to_sibling ConnectingAnimation + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + ConnectingButtonBackground + { + ControlName RuiPanel + classname ConnectingHUD + wide 100 + tall 40 + ypos -220 + xpos -462 + zpos 100 + + rui "ui/knowledgebase_panel.rpak" + + pin_to_sibling ConnectingAnimation + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + // PasswordProtected + + // BtnServerPasswordProtected (lock icons) dont pin to specified siblings + // Their 0,0 is the screen 0,0 + // Too lazy to fix hopefully doesn't break on other resolutions + BtnServerPasswordProtectedTab + { + ControlName ImagePanel + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + + pin_to_sibling RowButtonsAnchor + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerPasswordProtected1 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 200 + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected2 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 239 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected3 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 279 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected4 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 319 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected5 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 359 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected6 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 399 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected7 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 439 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected8 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 479 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected9 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 519 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected10 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 559 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected11 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 399 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected12 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 639 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected13 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 679 + + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected14 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 719 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPasswordProtected15 + { + ControlName ImagePanel + classname ServerLock + image "ui/menu/common/locked_icon" + scaleImage 1 + wide 48 + tall 48 + xpos 94 + ypos 759 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // Name + BtnServerNameTab + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#SERVERS_COLUMN" + wide 600 + xpos -4 + ypos -1 + + scriptID 999 + + pin_to_sibling BtnServerPasswordProtectedTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + navDown BtnServer1 + navRight BtnServerPlayersTab + } + + BtnServerName0 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + interactive false + + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName1 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName2 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName3 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName4 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName5 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName6 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName7 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName8 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName9 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName10 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName11 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName12 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName13 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerName14 + { + ControlName Label + labelText "" + textAlignment west + classname ServerName + wide 586 + tall 44 + ypos -44 + xpos -14 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + + // Players + BtnServerPlayersTab + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#PLAYERS_COLUMN" + wide 104 + xpos 4 + + scriptID 999 + + pin_to_sibling BtnServerNameTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + navDown BtnServer1 + navLeft BtnServerNameTab + navRight BtnServerMapTab + } + + BtnServerPlayers1 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers2 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers3 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers4 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers5 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers6 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers7 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers8 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers9 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers10 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers11 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers12 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers13 + { + ControlName Label + labelText "16/16" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers14 + { + ControlName Label + labelText "8/8" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerPlayers15 + { + ControlName Label + labelText "" + classname PlayerCount + textAlignment center + wide 104 + tall 44 + ypos -44 + xpos -600 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // Map + BtnServerMapTab + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#MAP_COLUMN" + textAlignment center + wide 140 + xpos 4 + + scriptID 999 + + pin_to_sibling BtnServerPlayersTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + navDown BtnServer1 + navLeft BtnServerPlayersTab + navRight BtnServerGamemodeTab + } + + BtnServerMap1 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap2 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap3 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap4 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap5 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap6 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap7 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap8 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap9 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap10 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap11 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap12 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap13 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap14 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMap15 + { + ControlName Label + labelText "" + classname ServerMap + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -709 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // Gamemode + BtnServerGamemodeTab + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#GAMEMODE_COLUMN" + wide 150 + xpos 4 + + scriptID 999 + + pin_to_sibling BtnServerMapTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + navDown BtnServer1 + navLeft BtnServerMapTab + navRight BtnServerLatencyTab + } + + BtnServerGamemode1 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode2 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode3 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode4 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode5 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode6 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode7 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode8 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode9 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode10 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode11 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode12 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode13 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode14 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerGamemode15 + { + ControlName Label + labelText "" + classname ServerGamemode + wide 140 + textAlignment center + tall 44 + ypos -44 + xpos -860 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // Latency + BtnServerLatencyTab + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#LATENCY_COLUMN" + wide 110 + xpos 4 + + scriptID 999 + + pin_to_sibling BtnServerGamemodeTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + navDown BtnServer1 + navLeft BtnServerGamemodeTab + navLeft BtnServerJoin + } + + BtnServerLatency1 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer1 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency2 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer2 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency3 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer3 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency4 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer4 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency5 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer5 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency6 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer6 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency7 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer7 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency8 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer8 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency9 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer9 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency10 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer10 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency11 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer11 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency12 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer12 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT } - - //test - //{ - // ControlName ListPanel - // xpos "200" - // ypos "200" - // zpos 999 - // wide "312" - // tall "340" - // autoResize "0" - // pinCorner "0" - // visible "1" - // enabled "1" - // tabPosition "0" - //} + BtnServerLatency13 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + pin_to_sibling BtnServer13 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency14 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer14 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerLatency15 + { + ControlName Label + labelText "" + classname Serverlatency + textAlignment center + wide 110 + tall 44 + ypos -44 + xpos -1006 + + pin_to_sibling BtnServer15 + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // Dividers: + + // Y + YDivider0 + { + ControlName ImagePanel + wide 2 + tall 641 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + xpos 3 + ypos -1 + + pin_to_sibling BtnServerNameTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + YDivider1 + { + ControlName ImagePanel + wide 2 + tall 641 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + xpos 3 + ypos -1 + + pin_to_sibling BtnServerPlayersTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + YDivider2 + { + ControlName ImagePanel + wide 2 + tall 641 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + xpos 3 + ypos -1 + + pin_to_sibling BtnServerMapTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + YDivider3 + { + ControlName ImagePanel + wide 2 + tall 641 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + xpos 3 + ypos -1 + + pin_to_sibling BtnServerGamemodeTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + YDivider4 + { + ControlName ImagePanel + wide 2 + tall 641 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + xpos 3 + ypos -1 + + pin_to_sibling BtnServerLatencyTab + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + // X + XDivider0 + { + ControlName ImagePanel + wide 1150 + tall 2 + visible 1 + image "vgui/hud/white" + drawColor "160 157 149 255" + scaleImage 1 + ypos 3 + xpos 37 + + pin_to_sibling BtnServerNameTab + pin_corner_to_sibling BOTTOM_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + // List: + BtnServerDummmyTop { + ControlName RuiButton + visible 1 + width 0 + height 0 + } BtnServer1 { ControlName RuiButton InheritProperties RuiSmallButton classname ServerButton scriptID 0 - navUp BtnServer15 - navDown BtnServer2 + wide 1120 + xpos -8 - pin_to_sibling ButtonRowAnchor - pin_corner_to_sibling TOP_LEFT - pin_to_sibling_corner TOP_LEFT + pin_to_sibling ButtonRowAnchor + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + navUp BtnServerDummmyTop + navRight BtnServerJoin + navDown BtnServer2 } BtnServer2 { @@ -80,11 +1779,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 1 + wide 1120 + pin_to_sibling BtnServer1 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer1 navDown BtnServer3 + navRight BtnServerJoin } BtnServer3 { @@ -92,11 +1794,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 2 + wide 1120 + pin_to_sibling BtnServer2 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer2 navDown BtnServer4 + navRight BtnServerJoin } BtnServer4 { @@ -104,12 +1809,15 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 3 + wide 1120 + pin_to_sibling BtnServer3 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT //ypos 11 navUp BtnServer3 navDown BtnServer5 + navRight BtnServerJoin } BtnServer5 { @@ -117,11 +1825,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 4 + wide 1120 + pin_to_sibling BtnServer4 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer4 navDown BtnServer6 + navRight BtnServerJoin } BtnServer6 { @@ -129,11 +1840,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 5 + wide 1120 + pin_to_sibling BtnServer5 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer5 navDown BtnServer7 + navRight BtnServerJoin } BtnServer7 { @@ -141,11 +1855,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 6 + wide 1120 + pin_to_sibling BtnServer6 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer6 navDown BtnServer8 + navRight BtnServerJoin } BtnServer8 { @@ -153,11 +1870,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 7 + wide 1120 + pin_to_sibling BtnServer7 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer7 navDown BtnServer9 + navRight BtnServerJoin } BtnServer9 { @@ -165,11 +1885,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 8 + wide 1120 + pin_to_sibling BtnServer8 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer8 navDown BtnServer10 + navRight BtnServerJoin } BtnServer10 { @@ -177,11 +1900,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 9 + wide 1120 + pin_to_sibling BtnServer9 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer9 navDown BtnServer11 + navRight BtnServerJoin } BtnServer11 { @@ -189,11 +1915,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 10 + wide 1120 + pin_to_sibling BtnServer10 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer10 navDown BtnServer12 + navRight BtnServerJoin } BtnServer12 { @@ -201,11 +1930,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 11 + wide 1120 + pin_to_sibling BtnServer11 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer11 navDown BtnServer13 + navRight BtnServerJoin } BtnServer13 { @@ -213,11 +1945,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 12 + wide 1120 + pin_to_sibling BtnServer12 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer12 navDown BtnServer14 + navRight BtnServerJoin } BtnServer14 { @@ -225,11 +1960,14 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 13 + wide 1120 + pin_to_sibling BtnServer13 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer13 navDown BtnServer15 + navRight BtnServerJoin } BtnServer15 { @@ -237,28 +1975,419 @@ resource/ui/menus/mods_browse.menu InheritProperties RuiSmallButton classname ServerButton scriptID 14 + wide 1120 + pin_to_sibling BtnServer14 pin_corner_to_sibling TOP_LEFT pin_to_sibling_corner BOTTOM_LEFT navUp BtnServer14 - navDown BtnServer1 + navRight BtnServerJoin + navDown BtnServerDummmyBottom + } + BtnServerDummmyBottom { + ControlName RuiButton + visible 1 + width 0 + height 0 + } + +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + BtnServerListUpArrow + { + ControlName RuiButton + InheritProperties RuiSmallButton + //labelText "A" + wide 40 + tall 40 + xpos 2 + ypos 2 + + image "vgui/hud/white" + drawColor "255 255 255 128" + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerListUpArrowPanel + { + ControlName RuiPanel + wide 40 + tall 40 + xpos 2 + ypos 2 + + rui "ui/control_options_description.rpak" + + visible 1 + zpos -1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerListDownArrow + { + ControlName RuiButton + InheritProperties RuiSmallButton + //labelText "V" + wide 40 + tall 40 + xpos 2 + ypos -604 + + image "vgui/hud/white" + drawColor "255 255 255 128" + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerListDownArrowPanel + { + ControlName RuiPanel + wide 40 + tall 40 + xpos 2 + ypos -604 + + rui "ui/control_options_description.rpak" + + visible 1 + zpos -1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerListSlider + { + ControlName RuiButton + InheritProperties RuiSmallButton + //labelText "V" + wide 40 + tall 562 + xpos 2 + ypos -40 + zpos 0 + + image "vgui/hud/white" + drawColor "255 255 255 128" + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerListSliderPanel + { + ControlName RuiPanel + wide 40 + tall 562 + xpos 2 + ypos -40 + + rui "ui/control_options_description.rpak" + + visible 1 + zpos -1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + // sh_menu_models.gnut has a global function which gets called when + // left mouse button gets called while hovering and has mouse + // deltaX; deltaY which we can yoink for ourselfes + MouseMovementCapture + { + ControlName CMouseMovementCapturePanel + wide 40 + tall 562 + xpos 2 + ypos -40 + zpos 1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner TOP_LEFT + } + + //MouseMovementCaptureaaaaaaa + //{ + // ControlName CMouseMovementCapturePanel + // wide %100 + // tall %100 + // xpos 0 + // ypos 0 + // zpos 2 + //} + +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + + FilterPanel + { + ControlName RuiPanel + wide 1200 + tall 153 + xpos -8 + + rui "ui/control_options_description.rpak" + + visible 1 + zpos -1 + + pin_to_sibling FilterButtonsRowAnchor + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + BtnSearchLabel + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#SEARCHBAR_LABEL" + textAlignment west + wide 500 + xpos -23 + ypos -16 + + wrap 1 + visible 1 + zpos 0 + + pin_to_sibling FilterButtonsRowAnchor + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + + navUp BtnServer15 + navDown SwtBtnSelectMap + } + + BtnServerSearch + { + ControlName TextEntry + zpos 100 // This works around input weirdness when the control is constructed by code instead of VGUI blackbox. + xpos -400 + ypos -5 + wide 390 + tall 30 + textHidden 0 + editable 1 + font Default_21 + allowRightClickMenu 0 + allowSpecialCharacters 0 + unicode 0 + + pin_to_sibling BtnSearchLabel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + + navUp BtnServer15 + navDown SwtBtnSelectMap + } + + SwtBtnSelectMap + { + ControlName RuiButton + InheritProperties SwitchButton + labelText "#MAP_FILTER" + ConVar "filter_map" + wide 500 + + pin_to_sibling BtnSearchLabel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + + navUp BtnServerSearch + navDown SwtBtnSelectGamemode + } + + SwtBtnSelectGamemode + { + ControlName RuiButton + InheritProperties SwitchButton + labelText "#GAMEMODE_FILTER" + ConVar "filter_gamemode" + wide 500 + + pin_to_sibling SwtBtnSelectMap + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + + navUp SwtBtnSelectMap + navDown SwtBtnHideFull + } + + SwtBtnHideFull + { + ControlName RuiButton + InheritProperties SwitchButton + labelText "#HIDE_FULL_FILTER" + ConVar "filter_hide_full" + wide 500 + + + list + { + "#SWITCH_NO" 0 + "#SWITCH_YES" 1 + } + + pin_to_sibling BtnSearchLabel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + + navUp SwtBtnSelectGamemode + navDown SwtBtnHideEmpty + } + + SwtBtnHideEmpty + { + ControlName RuiButton + InheritProperties SwitchButton + labelText "#HIDE_EMPTY_FILTER" + ConVar "filter_hide_empty" + wide 500 + + + list + { + "#SWITCH_NO" 0 + "#SWITCH_YES" 1 + } + + pin_to_sibling SwtBtnHideFull + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + + navUp SwtBtnHideFull + navDown SwtBtnHideProtected + } + + SwtBtnHideProtected + { + ControlName RuiButton + InheritProperties SwitchButton + labelText "#HIDE_PROT_FILTER" + ConVar "filter_hide_protected" + wide 500 + + list + { + "#SWITCH_NO" 0 + "#SWITCH_YES" 1 } - + + pin_to_sibling SwtBtnHideEmpty + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + + navUp SwtBtnHideEmpty + navDown BtnFiltersClear + } + + BtnFiltersClear + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#CLEAR_FILTERS" + wide 100 + xpos -17 + ypos -57 + zpos 90 + + scriptID 999 + + pin_to_sibling FilterPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner BOTTOM_RIGHT + + navUp SwtBtnHideProtected + navDown BtnDummyAfterFilterClear + navLeft SwtBtnHideProtected + navRight BtnServerJoin + } + + BtnDummyAfterFilterClear { + ControlName RuiButton + width 0 + height 0 + visible 1 + } //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - LabelDetails + ServerDetailsPanel { ControlName RuiPanel - xpos 675 + xpos 1300 ypos 160 tall 800 - wide 950 - rui "ui/knowledgebase_panel.rpak" + wide 500 + rui "ui/control_options_description.rpak" wrap 1 visible 1 zpos -1 } + //TestPanel + //{ + // ControlName RuiPanel + // tall 420 + // wide 500 + // ypos -330 + // rui "ui/control_options_description.rpak" + // wrap 1 + // visible 1 + // zpos -1 + + // pin_to_sibling ServerDetailsPanel + // pin_corner_to_sibling TOP_LEFT + // pin_to_sibling_corner TOP_LEFT + //} + + LabelDescription + { + ControlName Label + textAlignment north + tall 420 + wide 460 + ypos -300 + xpos -20 + + wrap 1 + visible 1 + zpos -1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + LabelMods + { + ControlName Label + textAlignment north + tall 420 + wide 460 + ypos -330 + xpos -20 + + wrap 1 + visible 1 + zpos -1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + NextMapImage { ControlName RuiPanel @@ -269,17 +2398,32 @@ resource/ui/menus/mods_browse.menu rui "ui/basic_menu_image.rpak" - pin_to_sibling LabelDetails + pin_to_sibling ServerDetailsPanel pin_corner_to_sibling TOP_RIGHT pin_to_sibling_corner TOP_RIGHT } + + NextMapBack + { + ControlName RuiPanel + tall 288 + wide 500 + rui "ui/control_options_description.rpak" + visible 0 + zpos 1 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + NextMapName { ControlName Label pin_to_sibling NextMapImage pin_corner_to_sibling BOTTOM_RIGHT pin_to_sibling_corner BOTTOM_RIGHT - + xpos -12 ypos 0 zpos 1 @@ -327,8 +2471,121 @@ resource/ui/menus/mods_browse.menu pin_to_sibling_corner TOP_RIGHT } + ServerName + { + ControlName Label + ypos -8 + xpos -8 + zpos 1 + wide 492 + tall 88 + wrap 1 + textAlignment north + + //labelText "Server name" + use_proportional_insets 1 + textinsetx 2 + font Default_28_DropShadow + allcaps 1 + fgcolor_override "255 255 255 255" + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_LEFT + } + + BtnServerDescription + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#DESCRIPTION" + + textAlignment center + wide 250 + zpos 999 + ypos -1 + + pin_to_sibling NextMapImage + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + BtnServerMods + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#MODS" + + textAlignment center + wide 250 + zpos 999 + + pin_to_sibling BtnServerDescription + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + } + + BtnServerJoin + { + ControlName RuiButton + InheritProperties RuiSmallButton + labelText "#JOIN_BUTTON" + wide 80 + xpos -17 + ypos -57 + zpos 90 + + scriptID 999 + + pin_to_sibling ServerDetailsPanel + pin_corner_to_sibling TOP_RIGHT + pin_to_sibling_corner BOTTOM_RIGHT + + navLeft BtnFiltersClear + navRight BtnServerSearch + } + //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + InGamePlayerLabel + { + ControlName Label + auto_wide_tocontents 1 + tall 40 + labelText "#INGAME_PLAYERS" + xpos -250 + ypos 30 + visible 1 + zpos 101 + + font Default_28_ShadowGlow + bgcolor_override "0 0 0 120" + fgcolor_override "255 255 255 175" + visible 1 + + pin_to_sibling FilterPanel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner BOTTOM_LEFT + } + + InGamePlayerCount + { + ControlName Label + auto_wide_tocontents 1 + tall 40 + labelText "" + font Default_28_ShadowGlow + bgcolor_override "0 0 0 120" + fgcolor_override "107 166 196 200" + xpos 6 + visible 1 + zpos 101 + + pin_to_sibling InGamePlayerLabel + pin_corner_to_sibling TOP_LEFT + pin_to_sibling_corner TOP_RIGHT + } + + FooterButtons { ControlName CNestedPanel diff --git a/Northstar.Client/mod/scripts/vscripts/sh_menu_models.gnut b/Northstar.Client/mod/scripts/vscripts/sh_menu_models.gnut index 58850e6a..cd663a06 100644 --- a/Northstar.Client/mod/scripts/vscripts/sh_menu_models.gnut +++ b/Northstar.Client/mod/scripts/vscripts/sh_menu_models.gnut @@ -2522,7 +2522,7 @@ while ( !clGlobal.initializedMenuModels ) WaitFrame() - + // setting menu camera while our viewentity isn't player will crash // unfortunately no way to close menu if we get our viewentity set while menu is open atm while ( GetViewEntity().GetClassName() == "class C_BaseEntity" ) @@ -2896,11 +2896,13 @@ { float screenScaleXModifier = 1920.0 / GetScreenSize()[0] // 1920 is base screen width float mouseXRotateDelta = deltaX * screenScaleXModifier * MOUSE_ROTATE_MULTIPLIER - //printt( "deltaX:", deltaX, "screenScaleModifier:", screenScaleModifier, "mouseRotateDelta:", mouseRotateDelta ) + //printt( "deltaX:", deltaX, "deltaY:", deltaY ) float screenScaleYModifier = 1080.0 / GetScreenSize()[1] // 1920 is base screen width float mouseYRotationDelta = deltaY * screenScaleYModifier * MOUSE_ROTATE_MULTIPLIER + UpdateMouseDeltaBuffer( deltaX, deltaY ) + RunMenuClientFunction( "UpdateMouseRotateDelta", mouseXRotateDelta, mouseYRotationDelta ) } #endif // UI 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 19a544cc..dd2f8864 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut @@ -1,14 +1,132 @@ +untyped +// Only way to get Hud_GetPos(sliderButton) working was to use untyped + global function AddNorthstarServerBrowserMenu global function ThreadedAuthAndConnectToServer +global function UpdateMouseDeltaBuffer + +// Stop peeking + const int BUTTONS_PER_PAGE = 15 +const float DOUBLE_CLICK_TIME_MS = 0.2 // unsure what the ideal value is + struct { - int page = 0 - int lastSelectedServer = 0 + int deltaX = 0 + int deltaY = 0 +} mouseDeltaBuffer + +struct { + bool hideFull = false + bool hideEmpty = false + bool hideProtected = false + bool useSearch = false + string searchTerm + array filterMaps + string filterMap + array filterGamemodes + string filterGamemode +} filterArguments + +struct { + // true = alphabeticaly false = reverse + bool serverName = true + bool serverPlayers = true + bool serverMap = true + bool serverGamemode = true + bool serverLatency = true + // 0 = none; 1 = name; 2 = players; 3 = map; 5 = gamemode; 6 = latency + int sortingBy = 0 +} filterDirection + +struct serverStruct { + int serverIndex + bool serverProtected + string serverName + int serverPlayers + int serverPlayersMax + string serverMap + string serverGamemode + int serverLatency +} + +struct { + var menu + int lastSelectedServer = 999 + int focusedServerIndex = 0 + int scrollOffset = 0 bool serverListRequestFailed = false + float serverSelectedTime = 0 + float serverSelectedTimeLast = 0 + int serverButtonFocusedID = 0 + bool shouldFocus = true + bool cancelConnection = false + + array serversArrayFiltered + + array serverButtons + array serversName + array playerCountLabels + array serversProtected + array serversMap + array serversGamemode + array serversLatency } file + + +bool function floatCompareInRange(float arg1, float arg2, float tolerance) +{ + if ( arg1 > arg2 - tolerance && arg1 < arg2 + tolerance) return true + return false +} + + + +// Hard coded for now +array function GetNorthstarGamemodes() +{ + array modes + + //modes.append( "#PL_aitdm" ) + modes.append( "#PL_pilot_hunter" ) + modes.append( "#PL_hardpoint" ) + //modes.append( "#PL_attrition" ) + modes.append( "#PL_capture_the_flag" ) + modes.append( "#PL_last_titan_standing" ) + modes.append( "#PL_pilot_skirmish" ) + modes.append( "#PL_live_fire" ) + modes.append( "#PL_marked_for_death" ) + modes.append( "#PL_titan_brawl" ) + //modes.append( "#PL_fd_easy" ) + //modes.append( "#PL_fd_normal" ) + //modes.append( "#PL_fd_hard" ) + //modes.append( "#PL_fd_master" ) + //modes.append( "#PL_fd_insane" ) + modes.append( "#PL_ffa" ) + modes.append( "#PL_fra" ) + modes.append( "#PL_coliseum" ) + modes.append( "#PL_aegis_titan_brawl" ) + modes.append( "#PL_titan_brawl_turbo" ) + modes.append( "#PL_aegis_last_titan_standing" ) + modes.append( "#PL_turbo_last_titan_standing" ) + modes.append( "#PL_rocket_arena" ) + modes.append( "#PL_all_holopilot" ) + modes.append( "#PL_gg" ) + modes.append( "#PL_tt" ) + modes.append( "#PL_inf" ) + modes.append( "#PL_kr" ) + modes.append( "#PL_fastball" ) + modes.append( "#GAMEMODE_hs" ) + modes.append( "#GAMEMODE_ctf_comp" ) + + + return modes +} +//////////////////////////// +// Init +//////////////////////////// void function AddNorthstarServerBrowserMenu() { AddMenu( "ServerBrowserMenu", $"resource/ui/menus/server_browser.menu", InitServerBrowserMenu, "#MENU_SERVER_BROWSER" ) @@ -16,219 +134,795 @@ void function AddNorthstarServerBrowserMenu() void function InitServerBrowserMenu() { - var menu = GetMenu( "ServerBrowserMenu" ) + file.menu = GetMenu( "ServerBrowserMenu" ) + + // Get menu stuff + file.serverButtons = GetElementsByClassname( file.menu, "ServerButton" ) + file.serversName = GetElementsByClassname( file.menu, "ServerName" ) + file.playerCountLabels = GetElementsByClassname( file.menu, "PlayerCount" ) + file.serversProtected = GetElementsByClassname( file.menu, "ServerLock" ) + file.serversMap = GetElementsByClassname( file.menu, "ServerMap" ) + file.serversGamemode = GetElementsByClassname( file.menu, "ServerGamemode" ) + file.serversLatency = GetElementsByClassname( file.menu, "ServerLatency" ) + + // Create filter arrays + filterArguments.filterMaps.extend(GetPrivateMatchMaps()) + filterArguments.filterMaps.insert(0, "SWITCH_ANY") + filterArguments.filterMaps.append("mp_lobby") + + foreach ( int enum_, string map in filterArguments.filterMaps ) + Hud_DialogList_AddListItem( Hud_GetChild( file.menu, "SwtBtnSelectMap" ) , map, string( enum_ ) ) + + + filterArguments.filterGamemodes = GetNorthstarGamemodes() + filterArguments.filterGamemodes.insert(0, "SWITCH_ANY") + + // GetGameModeDisplayName( mode ) requires server talk even if it can be entirely client side + foreach ( int enum_, string mode in filterArguments.filterGamemodes ) + Hud_DialogList_AddListItem( Hud_GetChild( file.menu, "SwtBtnSelectGamemode" ) , mode, string( enum_ ) ) + + + // Event handlers + AddMenuEventHandler( file.menu, eUIEvent.MENU_CLOSE, OnCloseServerBrowserMenu ) + + + + AddMenuEventHandler( file.menu, eUIEvent.MENU_OPEN, OnServerBrowserMenuOpened ) + AddMenuFooterOption( file.menu, BUTTON_B, "#B_BUTTON_BACK", "#BACK" ) + AddMenuFooterOption( file.menu, BUTTON_Y, "#Y_REFRESH_SERVERS", "#REFRESH_SERVERS", RefreshServers ) + + // Setup server buttons + var width = 1120.0 * (GetScreenSize()[1] / 1080.0) + foreach ( var button in GetElementsByClassname( file.menu, "ServerButton" ) ) + { + AddButtonEventHandler( button, UIE_CLICK, OnServerButtonClicked ) + AddButtonEventHandler( button, UIE_GET_FOCUS, OnServerButtonFocused ) + Hud_SetWidth( button , width ) + } + + AddButtonEventHandler( Hud_GetChild( file.menu , "BtnServerDummmyTop" ), UIE_GET_FOCUS, OnHitDummyTop ) + AddButtonEventHandler( Hud_GetChild( file.menu , "BtnServerDummmyBottom" ), UIE_GET_FOCUS, OnHitDummyBottom ) + + + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerJoin"), UIE_CLICK, OnServerSelected ) + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerListUpArrow"), UIE_CLICK, OnUpArrowSelected ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerListDownArrow"), UIE_CLICK, OnDownArrowSelected ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnDummyAfterFilterClear"), UIE_GET_FOCUS, OnHitDummyAfterFilterClear ) + + + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnFiltersClear"), UIE_CLICK, OnBtnFiltersClear_Activate ) + + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerNameTab"), UIE_CLICK, SortServerListByName ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerPlayersTab"), UIE_CLICK, SortServerListByPlayers ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerMapTab"), UIE_CLICK, SortServerListByMap ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerGamemodeTab"), UIE_CLICK, SortServerListByGamemode ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerLatencyTab"), UIE_CLICK, SortServerListByLatency ) + + + AddButtonEventHandler( Hud_GetChild( file.menu, "SwtBtnSelectMap"), UIE_CHANGE, FilterAndUpdateList ) + AddButtonEventHandler( Hud_GetChild( file.menu, "SwtBtnSelectGamemode"), UIE_CHANGE, FilterAndUpdateList ) + AddButtonEventHandler( Hud_GetChild( file.menu, "SwtBtnHideFull"), UIE_CHANGE, FilterAndUpdateList ) + AddButtonEventHandler( Hud_GetChild( file.menu, "SwtBtnHideEmpty"), UIE_CHANGE, FilterAndUpdateList ) + AddButtonEventHandler( Hud_GetChild( file.menu, "SwtBtnHideProtected"), UIE_CHANGE, FilterAndUpdateList ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnSearchLabel"), UIE_CHANGE, FilterAndUpdateList ) + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerSearch"), UIE_CHANGE, FilterAndUpdateList ) + + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerDescription"), UIE_CLICK, ShowServerDescription ) + AddButtonEventHandler( Hud_GetChild( file.menu, "BtnServerMods"), UIE_CLICK, ShowServerMods ) + + AddButtonEventHandler( Hud_GetChild( file.menu, "ConnectingButton"), UIE_CLICK, ConnectingButton_Activate ) + + + // Hidden cause no need, if server descriptions become too long use this + Hud_SetEnabled( Hud_GetChild( file.menu, "BtnServerDescription"), false) + Hud_SetEnabled( Hud_GetChild( file.menu, "BtnServerMods"), false) + Hud_SetText( Hud_GetChild( file.menu, "BtnServerDescription"), "") + Hud_SetText( Hud_GetChild( file.menu, "BtnServerMods"), "") + + // Unfinished features + Hud_SetLocked( Hud_GetChild( file.menu, "BtnServerLatencyTab" ), true ) + + // Rui is a pain + RuiSetString( Hud_GetRui( Hud_GetChild( file.menu, "SwtBtnHideFull")), "buttonText", "") + RuiSetString( Hud_GetRui( Hud_GetChild( file.menu, "SwtBtnHideEmpty")), "buttonText", "") + RuiSetString( Hud_GetRui( Hud_GetChild( file.menu, "SwtBtnHideProtected")), "buttonText", "") + RuiSetString( Hud_GetRui( Hud_GetChild( file.menu, "SwtBtnSelectMap")), "buttonText", "") + RuiSetString( Hud_GetRui( Hud_GetChild( file.menu, "SwtBtnSelectGamemode")), "buttonText", "") + + + ToggleConnectingHUD(false) + + // UI was cut off on some aspect ratios; not perfect + UpdateServerInfoBasedOnRes() +} + +//////////////////////////// +// Slider +//////////////////////////// +void function UpdateMouseDeltaBuffer(int x, int y) +{ + mouseDeltaBuffer.deltaX += x + mouseDeltaBuffer.deltaY += y + + SliderBarUpdate() +} + +void function FlushMouseDeltaBuffer() +{ + mouseDeltaBuffer.deltaX = 0 + mouseDeltaBuffer.deltaY = 0 +} + + +void function SliderBarUpdate() +{ + if ( file.serversArrayFiltered.len() <= 15 ) + { + FlushMouseDeltaBuffer() + return + } + + var sliderButton = Hud_GetChild( file.menu , "BtnServerListSlider" ) + var sliderPanel = Hud_GetChild( file.menu , "BtnServerListSliderPanel" ) + var movementCapture = Hud_GetChild( file.menu , "MouseMovementCapture" ) + + Hud_SetFocused(sliderButton) + + float minYPos = -40.0 * (GetScreenSize()[1] / 1080.0) + float maxHeight = 562.0 * (GetScreenSize()[1] / 1080.0) + float maxYPos = minYPos - (maxHeight - Hud_GetHeight( sliderPanel )) + float useableSpace = (maxHeight - Hud_GetHeight( sliderPanel )) + + float jump = minYPos - (useableSpace / ( float( file.serversArrayFiltered.len()))) + + // got local from official respaw scripts, without untyped throws an error + local pos = Hud_GetPos(sliderButton)[1] + local newPos = pos - mouseDeltaBuffer.deltaY + FlushMouseDeltaBuffer() + + if ( newPos < maxYPos ) newPos = maxYPos + if ( newPos > minYPos ) newPos = minYPos + + Hud_SetPos( sliderButton , 2, newPos ) + Hud_SetPos( sliderPanel , 2, newPos ) + Hud_SetPos( movementCapture , 2, newPos ) + + file.scrollOffset = -int( ( (newPos - minYPos) / useableSpace ) * (file.serversArrayFiltered.len() - 15) ) + UpdateShownPage() +} + +void function UpdateListSliderHeight( float servers ) +{ + var sliderButton = Hud_GetChild( file.menu , "BtnServerListSlider" ) + var sliderPanel = Hud_GetChild( file.menu , "BtnServerListSliderPanel" ) + var movementCapture = Hud_GetChild( file.menu , "MouseMovementCapture" ) + + float maxHeight = 562.0 * (GetScreenSize()[1] / 1080.0) + + float height = maxHeight * (15.0 / servers ) + + if ( height > maxHeight ) height = maxHeight + + Hud_SetHeight( sliderButton , height ) + Hud_SetHeight( sliderPanel , height ) + Hud_SetHeight( movementCapture , height ) +} + + +void function UpdateListSliderPosition( int servers ) +{ + var sliderButton = Hud_GetChild( file.menu , "BtnServerListSlider" ) + var sliderPanel = Hud_GetChild( file.menu , "BtnServerListSliderPanel" ) + var movementCapture = Hud_GetChild( file.menu , "MouseMovementCapture" ) + + float minYPos = -40.0 * (GetScreenSize()[1] / 1080.0) + float useableSpace = (562.0 * (GetScreenSize()[1] / 1080.0) - Hud_GetHeight( sliderPanel )) + + float jump = minYPos - (useableSpace / ( float( servers ) - 15.0 ) * file.scrollOffset) - AddMenuEventHandler( menu, eUIEvent.MENU_OPEN, OnServerBrowserMenuOpened ) - AddMenuFooterOption( menu, BUTTON_B, "#B_BUTTON_BACK", "#BACK" ) - AddMenuFooterOption( menu, BUTTON_Y, "#Y_REFRESH_SERVERS", "#REFRESH_SERVERS", RefreshServers ) - AddMenuFooterOption( menu, BUTTON_SHOULDER_LEFT, "#PRIVATE_MATCH_PAGE_PREV", "#PRIVATE_MATCH_PAGE_PREV", CycleServersBack ) - AddMenuFooterOption( menu, BUTTON_SHOULDER_RIGHT, "#PRIVATE_MATCH_PAGE_NEXT", "#PRIVATE_MATCH_PAGE_NEXT", CycleServersForward ) - - foreach ( var button in GetElementsByClassname( GetMenu( "ServerBrowserMenu" ), "ServerButton" ) ) + //jump = jump * (GetScreenSize()[1] / 1080.0) + + if ( jump > minYPos ) jump = minYPos + + Hud_SetPos( sliderButton , 2, jump ) + Hud_SetPos( sliderPanel , 2, jump ) + Hud_SetPos( movementCapture , 2, jump ) +} + +void function OnScrollDown( var button ) +{ + if (file.serversArrayFiltered.len() <= 15) return + file.scrollOffset += 5 + if (file.scrollOffset + BUTTONS_PER_PAGE > file.serversArrayFiltered.len()) { + file.scrollOffset = file.serversArrayFiltered.len() - BUTTONS_PER_PAGE + } + UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) +} + +void function OnScrollUp( var button ) +{ + file.scrollOffset -= 5 + if (file.scrollOffset < 0) { + file.scrollOffset = 0 + } + UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) +} + +//////////////////////////// +// Connecting pop-up +//////////////////////////// +void function ToggleConnectingHUD( bool vis ) +{ + foreach (e in GetElementsByClassname(file.menu, "connectingHUD")) { + Hud_SetEnabled( e, vis ) + Hud_SetVisible( e, vis ) + } + + if ( vis ) Hud_SetFocused( Hud_GetChild( file.menu, "ConnectingButton" ) ) +} + +void function ConnectingButton_Activate( var button ) +{ + file.cancelConnection = true +} + +//////////////////////////// +// Aspect ratio compensation +//////////////////////////// +// No way to get aspect ratio sadly +// This doesn't werk on some obscure resolutions, mostly really small 4:3 +void function UpdateServerInfoBasedOnRes() +{ + if (floatCompareInRange(float(GetScreenSize()[0]) / float(GetScreenSize()[1]) , 1.6, 0.07)) // 16/10 + { + Hud_SetWidth( Hud_GetChild(file.menu, "ServerName"), 392) + Hud_SetWidth( Hud_GetChild(file.menu, "NextMapImage"), 400) + Hud_SetWidth( Hud_GetChild(file.menu, "NextMapBack"), 400) + Hud_SetWidth( Hud_GetChild(file.menu, "LabelMods"), 360) + Hud_SetWidth( Hud_GetChild(file.menu, "LabelDescription"), 360) + Hud_SetWidth( Hud_GetChild(file.menu, "ServerDetailsPanel"), 400) + } + if(floatCompareInRange(float(GetScreenSize()[0]) / float(GetScreenSize()[1]) , 1.3, 0.055)) // 4/3 { - AddButtonEventHandler( button, UIE_GET_FOCUS, OnServerFocused ) - AddButtonEventHandler( button, UIE_CLICK, OnServerSelected ) + Hud_SetWidth( Hud_GetChild(file.menu, "ServerName"), 292) + Hud_SetWidth( Hud_GetChild(file.menu, "NextMapImage"), 300) + Hud_SetWidth( Hud_GetChild(file.menu, "NextMapBack"), 300) + Hud_SetWidth( Hud_GetChild(file.menu, "LabelMods"), 260) + Hud_SetWidth( Hud_GetChild(file.menu, "LabelDescription"), 260) + Hud_SetWidth( Hud_GetChild(file.menu, "ServerDetailsPanel"), 300) } } +//////////////////////////// +// Open/close callbacks +//////////////////////////// +void function OnCloseServerBrowserMenu() +{ + DeregisterButtonPressedCallback(MOUSE_WHEEL_UP , OnScrollUp) + DeregisterButtonPressedCallback(MOUSE_WHEEL_DOWN , OnScrollDown) + DeregisterButtonPressedCallback(KEY_TAB , OnKeyTabPressed) +} + void function OnServerBrowserMenuOpened() { - Hud_SetText( Hud_GetChild( GetMenu( "ServerBrowserMenu" ), "Title" ), "#MENU_TITLE_SERVER_BROWSER" ) + Hud_SetText( Hud_GetChild( file.menu, "Title" ), "#MENU_TITLE_SERVER_BROWSER" ) UI_SetPresentationType( ePresentationType.KNOWLEDGEBASE_MAIN ) - - file.page = 0 + + file.scrollOffset = 0 // dont rerequest if we came from the connect menu if ( !NSIsRequestingServerList() && uiGlobal.lastMenuNavDirection != MENU_NAV_BACK ) { NSClearRecievedServerList() NSRequestServerList() } - + thread WaitForServerListRequest() + + + RegisterButtonPressedCallback(MOUSE_WHEEL_UP , OnScrollUp) + RegisterButtonPressedCallback(MOUSE_WHEEL_DOWN , OnScrollDown) + RegisterButtonPressedCallback(KEY_TAB , OnKeyTabPressed) } -void function RefreshServers( var button ) +//////////////////////////// +// Arrow navigation fuckery +//////////////////////////// +bool function IsFilterPanelElementFocused() { + // get name of focused element + var focusedElement = GetFocus(); + var name = Hud_GetHudName(focusedElement); + + print(name) + + // kinda sucks but just check if any of the filter elements + // has focus. would be nice to have tags or sth here + bool match = (name == "FilterPanel") || + (name == "BtnSearchLabel") || + (name == "BtnServerSearch") || + (name == "SwtBtnSelectMap") || + (name == "SwtBtnSelectGamemode") || + (name == "SwtBtnHideFull") || + (name == "SwtBtnHideEmpty") || + (name == "SwtBtnHideProtected") || + (name == "BtnFiltersClear") || + (name == "BtnDummyAfterFilterClear"); + + + return match; +} + +void function OnKeyTabPressed(var button) { + // toggle focus between server list and filter panel + if (IsFilterPanelElementFocused()) { + // print("Switching focus from filter panel to server list") + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServer1")) + } + else { + // print("Switching focus from server list to filter panel") + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServerSearch")) + HideServerInfo() + } +} + +void function OnHitDummyTop(var button) { + file.scrollOffset -= 1 + if (file.scrollOffset < 0) { + // was at top already + file.scrollOffset = 0 + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServerNameTab")) + } else { + // only update if list position changed + UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) + DisplayFocusedServerInfo(file.serverButtonFocusedID) + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServer1")) + } +} + +void function OnHitDummyBottom(var button) { + file.scrollOffset += 1 + if (file.scrollOffset + BUTTONS_PER_PAGE > file.serversArrayFiltered.len()) + { + // was at bottom already + file.scrollOffset = file.serversArrayFiltered.len() - BUTTONS_PER_PAGE + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServerSearch")) + } else { + // only update if list position changed + UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) + DisplayFocusedServerInfo(file.serverButtonFocusedID) + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServer15")) + } +} + +void function OnHitDummyAfterFilterClear(var button) { + Hud_SetFocused(Hud_GetChild(file.menu, "BtnServer1")) +} + + +void function OnDownArrowSelected( var button ) { - if ( NSIsRequestingServerList() ) - return - - file.page = 0 - file.serverListRequestFailed = false - NSClearRecievedServerList() - NSRequestServerList() - - thread WaitForServerListRequest() + if (file.serversArrayFiltered.len() <= 15) return + file.scrollOffset += 1 + if (file.scrollOffset + BUTTONS_PER_PAGE > file.serversArrayFiltered.len()) { + file.scrollOffset = file.serversArrayFiltered.len() - BUTTONS_PER_PAGE + } + UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) } -void function CycleServersBack( var button ) + +void function OnUpArrowSelected( var button ) { - if ( file.page == 0 ) - return - - file.page-- + file.scrollOffset -= 1 + if (file.scrollOffset < 0) { + file.scrollOffset = 0 + } UpdateShownPage() + UpdateListSliderPosition( file.serversArrayFiltered.len() ) +} + + +//////////////////////////// +// Unused +//////////////////////////// +void function ShowServerDescription( var button ) +{ + Hud_SetVisible( Hud_GetChild( file.menu, "LabelDescription"), true) + Hud_SetVisible( Hud_GetChild( file.menu, "LabelMods"), false) +} + +void function ShowServerMods( var button ) +{ + Hud_SetVisible( Hud_GetChild( file.menu, "LabelDescription"), false) + Hud_SetVisible( Hud_GetChild( file.menu, "LabelMods"), true) +} + +//////////////////////////// +// Server list; filter,update,... +//////////////////////////// +void function HideServerInfo() { + Hud_SetVisible(Hud_GetChild(file.menu, "BtnServerDescription"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "BtnServerMods"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "BtnServerJoin"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "LabelDescription"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "LabelMods"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "NextMapImage"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "NextMapBack"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "NextMapName"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "ServerName"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "NextModeIcon"), false) + Hud_SetVisible(Hud_GetChild(file.menu, "NextGameModeName"), false) } -void function CycleServersForward( var button ) +void function OnBtnFiltersClear_Activate( var button ) { - if ( ( file.page + 1 ) * BUTTONS_PER_PAGE >= NSGetServerCount() ) + Hud_SetText( Hud_GetChild( file.menu, "BtnServerSearch" ), "" ) + + SetConVarBool( "filter_hide_empty", false ) + SetConVarBool( "filter_hide_full", false ) + SetConVarBool( "filter_hide_protected", false ) + SetConVarInt( "filter_map", 0 ) + SetConVarInt( "filter_gamemode", 0 ) + + FilterAndUpdateList(0) +} + +void function FilterAndUpdateList( var n ) +{ + filterArguments.searchTerm = Hud_GetUTF8Text( Hud_GetChild( file.menu, "BtnServerSearch" ) ) + if ( filterArguments.searchTerm == "" ) filterArguments.useSearch = false else filterArguments.useSearch = true + filterArguments.filterMap = filterArguments.filterMaps[ GetConVarInt( "filter_map" ) ] + filterArguments.filterGamemode = filterArguments.filterGamemodes[ GetConVarInt( "filter_gamemode" ) ] + filterArguments.hideEmpty = GetConVarBool( "filter_hide_empty" ) + filterArguments.hideFull = GetConVarBool( "filter_hide_full" ) + filterArguments.hideProtected = GetConVarBool( "filter_hide_protected" ) + + file.scrollOffset = 0 + UpdateListSliderPosition( file.serversArrayFiltered.len() ) + + FilterServerList() + + switch ( filterDirection.sortingBy ) + { + case 0: + UpdateShownPage() + break + case 1: + filterDirection.serverName = !filterDirection.serverName + SortServerListByName(0) + break + case 2: + filterDirection.serverPlayers = !filterDirection.serverPlayers + SortServerListByPlayers(0) + break + case 3: + filterDirection.serverMap = !filterDirection.serverMap + SortServerListByMap(0) + break + case 5: // 4 skipped cause it doesn't work respawn pls fix + filterDirection.serverGamemode = !filterDirection.serverGamemode + SortServerListByGamemode(0) + break + case 6: + filterDirection.serverLatency = !filterDirection.serverLatency + SortServerListByLatency(0) + break + default: + printt( "How the f did you get here" ) + } + + if ( file.shouldFocus ) + { + file.shouldFocus = false + Hud_SetFocused( Hud_GetChild( file.menu, "BtnServer1" ) ) + } +} + + +void function RefreshServers( var button ) +{ + if ( NSIsRequestingServerList() ) return - - file.page++ - UpdateShownPage() + + file.serverListRequestFailed = false + file.scrollOffset = 0 + NSClearRecievedServerList() + NSRequestServerList() + + thread WaitForServerListRequest() } + void function WaitForServerListRequest() { - var menu = GetMenu( "ServerBrowserMenu" ) - array serverButtons = GetElementsByClassname( menu, "ServerButton" ) - foreach ( var button in serverButtons ) + + for ( int i = 0; i < 15; i++) { - Hud_SetEnabled( button, false ) - Hud_SetVisible( button, false ) - } - - Hud_SetVisible( Hud_GetChild( menu, "LabelDetails" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextMapImage" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextMapName" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextModeIcon" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextGameModeName" ), false ) - - Hud_SetEnabled( serverButtons[ 0 ], true ) - Hud_SetVisible( serverButtons[ 0 ], true ) - - SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_WAITINGFORSERVERS" ) - + Hud_SetVisible( file.serversProtected[ i ], false ) + Hud_SetVisible( file.serverButtons[ i ], false ) + Hud_SetText( file.serversName[ i ], "" ) + Hud_SetText( file.playerCountLabels[ i ], "" ) + Hud_SetText( file.serversMap[ i ], "" ) + Hud_SetText( file.serversGamemode[ i ], "" ) + Hud_SetText( file.serversLatency[ i ], "" ) + } + + + HideServerInfo() + + + Hud_SetVisible( file.serversName[ 0 ], true ) + + Hud_SetText( file.serversName[ 0 ], "#NS_SERVERBROWSER_WAITINGFORSERVERS" ) + // wait for request to complete while ( NSIsRequestingServerList() ) WaitFrame() - + file.serverListRequestFailed = !NSMasterServerConnectionSuccessful() if ( file.serverListRequestFailed ) - SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_CONNECTIONFAILED" ) + { + Hud_SetText( file.serversName[ 0 ], "#NS_SERVERBROWSER_CONNECTIONFAILED" ) + } else - UpdateShownPage() + { + FilterAndUpdateList(0) + } } -void function UpdateShownPage() + + +void function FilterServerList() { - var menu = GetMenu( "ServerBrowserMenu" ) + file.serversArrayFiltered.clear() + int totalPlayers = 0 - // hide old ui elements - array serverButtons = GetElementsByClassname( menu, "ServerButton" ) - foreach ( var button in serverButtons ) + for ( int i = 0; i < NSGetServerCount(); i++ ) { - Hud_SetEnabled( button, false ) - Hud_SetVisible( button, false ) - } - - Hud_SetFocused( serverButtons[ serverButtons.len() - 1 ] ) - - Hud_SetVisible( Hud_GetChild( menu, "LabelDetails" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextMapImage" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextMapName" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextModeIcon" ), false ) - Hud_SetVisible( Hud_GetChild( menu, "NextGameModeName" ), false ) - - if ( NSGetServerCount() == 0 ) + serverStruct tempServer + tempServer.serverIndex = i + tempServer.serverProtected = NSServerRequiresPassword( i ) + tempServer.serverName = NSGetServerName( i ) + tempServer.serverPlayers = NSGetServerPlayerCount( i ) + tempServer.serverPlayersMax = NSGetServerMaxPlayerCount( i ) + tempServer.serverMap = NSGetServerMap( i ) + tempServer.serverGamemode = GetGameModeDisplayName( NSGetServerPlaylist ( i ) ) + + totalPlayers += tempServer.serverPlayers + + + // Branchless programming ;) + if (!(filterArguments.hideEmpty && tempServer.serverPlayers == 0) && !(filterArguments.hideFull && tempServer.serverPlayers == tempServer.serverPlayersMax) && !(filterArguments.hideProtected && tempServer.serverProtected)) + { + if ( filterArguments.useSearch ) + { + string sName = tempServer.serverName.tolower() + string sTerm = filterArguments.searchTerm.tolower() + + if ( sName.find(sTerm) != null) + { + if (filterArguments.filterMap != "SWITCH_ANY" && filterArguments.filterMap == tempServer.serverMap) + { + CheckGamemode( tempServer ) + } + else if (filterArguments.filterMap == "SWITCH_ANY") + { + CheckGamemode( tempServer ) + } + } + } + else + { + if (filterArguments.filterMap != "SWITCH_ANY" && filterArguments.filterMap == tempServer.serverMap) + { + CheckGamemode( tempServer ) + } + else if (filterArguments.filterMap == "SWITCH_ANY") + { + CheckGamemode( tempServer ) + } + } + } + } + + + printt("Better.Serverbrowser:------------------------") + printt("Server count: ", NSGetServerCount()) + printt("Filtered count: ", file.serversArrayFiltered.len()) + printt("Total players: ", totalPlayers) + printt("This message gets shown only on full refresh") + printt("---------------------------------------------") + + Hud_SetText( Hud_GetChild( file.menu, "InGamePlayerCount" ), string( totalPlayers ) ) +} + +void function CheckGamemode( serverStruct t ) +{ + if (filterArguments.filterGamemode != "SWITCH_ANY" && filterArguments.filterGamemode == t.serverGamemode) { - Hud_SetEnabled( serverButtons[ 0 ], true ) - Hud_SetVisible( serverButtons[ 0 ], true ) - SetButtonRuiText( serverButtons[ 0 ], "#NS_SERVERBROWSER_NOSERVERS" ) - return + file.serversArrayFiltered.append( t ) } - - // this trycatch likely isn't necessary, but i can't test whether this'll error on higher pagecounts and want to go sleep - try + else if (filterArguments.filterGamemode == "SWITCH_ANY") { - for ( int i = 0; ( file.page * BUTTONS_PER_PAGE ) + i < NSGetServerCount() && i < serverButtons.len(); i++ ) + file.serversArrayFiltered.append( t ) + } +} + + +void function UpdateShownPage() +{ + + for ( int i = 0; i < 15; i++) { - int serverIndex = ( file.page * BUTTONS_PER_PAGE ) + i - - Hud_SetEnabled( serverButtons[ i ], true ) - Hud_SetVisible( serverButtons[ i ], true ) - SetButtonRuiText( serverButtons[ i ], NSGetServerName( serverIndex ) ) + Hud_SetVisible( file.serversProtected[ i ], false ) + Hud_SetVisible( file.serverButtons[ i ], false ) + Hud_SetText( file.serversName[ i ], "" ) + Hud_SetText( file.playerCountLabels[ i ], "" ) + Hud_SetText( file.serversMap[ i ], "" ) + Hud_SetText( file.serversGamemode[ i ], "" ) + Hud_SetText( file.serversLatency[ i ], "" ) } + + int j = file.serversArrayFiltered.len() > 15 ? 15 : file.serversArrayFiltered.len() + + for ( int i = 0; i < j; i++ ) + { + + int buttonIndex = file.scrollOffset + i + int serverIndex = file.serversArrayFiltered[ buttonIndex ].serverIndex + + Hud_SetEnabled( file.serverButtons[ i ], true ) + Hud_SetVisible( file.serverButtons[ i ], true ) + + Hud_SetVisible( file.serversProtected[ i ], file.serversArrayFiltered[ buttonIndex ].serverProtected ) + Hud_SetText( file.serversName[ i ], file.serversArrayFiltered[ buttonIndex ].serverName ) + Hud_SetText( file.playerCountLabels[ i ], format( "%i/%i", file.serversArrayFiltered[ buttonIndex ].serverPlayers, file.serversArrayFiltered[ buttonIndex ].serverPlayersMax ) ) + Hud_SetText( file.serversMap[ i ], GetMapDisplayName( file.serversArrayFiltered[ buttonIndex ].serverMap ) ) + Hud_SetText( file.serversGamemode[ i ], file.serversArrayFiltered[ buttonIndex ].serverGamemode ) } - catch(ex) {} + + + if ( NSGetServerCount() == 0 ) + { + Hud_SetEnabled( file.serverButtons[ 0 ], true ) + Hud_SetVisible( file.serverButtons[ 0 ], true ) + Hud_SetText( file.serversName[ 0 ], "#NS_SERVERBROWSER_NOSERVERS" ) + } + UpdateListSliderHeight( float( file.serversArrayFiltered.len() ) ) +} + +void function OnServerButtonFocused( var button ) +{ + int scriptID = int (Hud_GetScriptID(button)) + file.serverButtonFocusedID = scriptID + DisplayFocusedServerInfo(scriptID); + } -void function OnServerFocused( var button ) +void function OnServerButtonClicked(var button) { + int scriptID = int (Hud_GetScriptID(button)) + + DisplayFocusedServerInfo(scriptID) + CheckDoubleClick(scriptID, true) +} + +void function CheckDoubleClick(int scriptID, bool wasClickNav) +{ + file.focusedServerIndex = file.serversArrayFiltered[ file.scrollOffset + scriptID ].serverIndex + int serverIndex = file.scrollOffset + scriptID + + bool sameServer = false + if (file.lastSelectedServer == serverIndex) sameServer = true + + + file.serverSelectedTimeLast = file.serverSelectedTime + file.serverSelectedTime = Time() + + printt(file.serverSelectedTime - file.serverSelectedTimeLast, file.lastSelectedServer, serverIndex) + + file.lastSelectedServer = serverIndex + + + if (wasClickNav && (file.serverSelectedTime - file.serverSelectedTimeLast < DOUBLE_CLICK_TIME_MS) && sameServer) + { + OnServerSelected(0) + } +} + +void function DisplayFocusedServerInfo( int scriptID) +{ + if (scriptID == 999 || scriptID == -1 || scriptID == 16) return + if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed ) return var menu = GetMenu( "ServerBrowserMenu" ) - int serverIndex = file.page * BUTTONS_PER_PAGE + int ( Hud_GetScriptID( button ) ) - // text panel - Hud_SetVisible( Hud_GetChild( menu, "LabelDetails" ), true ) - var textRui = Hud_GetRui( Hud_GetChild( menu, "LabelDetails" ) ) - RuiSetGameTime( textRui, "startTime", -99999.99 ) // make sure it skips the whole animation for showing this - RuiSetString( textRui, "messageText", FormatServerDescription( serverIndex ) ) + int serverIndex = file.scrollOffset + scriptID - // map name/image - string map = NSGetServerMap( serverIndex ) + + Hud_SetVisible( Hud_GetChild( menu, "BtnServerDescription" ), true ) + Hud_SetVisible( Hud_GetChild( menu, "BtnServerMods" ), true ) + Hud_SetVisible( Hud_GetChild( menu, "BtnServerJoin" ), true ) + // 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 Hud_SetVisible( Hud_GetChild( menu, "NextMapImage" ), true ) + Hud_SetVisible( Hud_GetChild( menu, "NextMapBack" ), true ) RuiSetImage( Hud_GetRui( Hud_GetChild( menu, "NextMapImage" ) ), "basicImage", GetMapImageForMapName( map ) ) Hud_SetVisible( Hud_GetChild( menu, "NextMapName" ), true ) Hud_SetText( Hud_GetChild( menu, "NextMapName" ), GetMapDisplayName( map ) ) + Hud_SetVisible( Hud_GetChild( menu, "ServerName" ), true ) + Hud_SetText( Hud_GetChild( menu, "ServerName" ), NSGetServerName( file.serversArrayFiltered[ serverIndex ].serverIndex ) ) // mode name/image - string mode = NSGetServerPlaylist( serverIndex ) + string mode = file.serversArrayFiltered[ serverIndex ].serverGamemode Hud_SetVisible( Hud_GetChild( menu, "NextModeIcon" ), true ) RuiSetImage( Hud_GetRui( Hud_GetChild( menu, "NextModeIcon" ) ), "basicImage", GetPlaylistThumbnailImage( mode ) ) Hud_SetVisible( Hud_GetChild( menu, "NextGameModeName" ), true ) - - string displayName = GetGameModeDisplayName( mode ) - if ( displayName.len() != 0 ) - Hud_SetText( Hud_GetChild( menu, "NextGameModeName" ), displayName ) + + if ( mode.len() != 0 ) + Hud_SetText( Hud_GetChild( menu, "NextGameModeName" ), mode ) else Hud_SetText( Hud_GetChild( menu, "NextGameModeName" ), "#NS_SERVERBROWSER_UNKNOWNMODE" ) } -string function FormatServerDescription( int server ) +string function FillInServerModsLabel( int server ) { - string ret = "\n\n\n\n" - - ret += NSGetServerName( server ) + "\n" - ret += format( "%i/%i players\n", NSGetServerPlayerCount( server ), NSGetServerMaxPlayerCount( server ) ) - ret += NSGetServerDescription( server ) + "\n\n" - - ret += "Required Mods: \n" + string ret + for ( int i = 0; i < NSGetServerRequiredModsCount( server ); i++ ) - ret += " " + NSGetServerRequiredModName( server, i ) + " v" + NSGetServerRequiredModVersion( server, i ) + "\n" - + { + ret += " " + ret += NSGetServerRequiredModName( server, i ) + " v" + NSGetServerRequiredModVersion( server, i ) + "\n" + } return ret } + void function OnServerSelected( var button ) { if ( NSIsRequestingServerList() || NSGetServerCount() == 0 || file.serverListRequestFailed ) return - int serverIndex = file.page * BUTTONS_PER_PAGE + int ( Hud_GetScriptID( button ) ) + int serverIndex = file.focusedServerIndex + file.lastSelectedServer = serverIndex // check mods - for ( int i = 0; i < NSGetServerRequiredModsCount( serverIndex ); i++ ) - { + for ( int i = 0; i < NSGetServerRequiredModsCount( serverIndex ); i++ ) + { if ( !NSGetModNames().contains( NSGetServerRequiredModName( serverIndex, i ) ) ) - { + { DialogData dialogData dialogData.header = "#ERROR" dialogData.message = "Missing mod \"" + NSGetServerRequiredModName( serverIndex, i ) + "\" v" + NSGetServerRequiredModVersion( serverIndex, i ) dialogData.image = $"ui/menu/common/dialog_error" - + #if PC_PROG AddDialogButton( dialogData, "#DISMISS" ) - + AddDialogFooter( dialogData, "#A_BUTTON_SELECT" ) #endif // PC_PROG AddDialogFooter( dialogData, "#B_BUTTON_DISMISS_RUI" ) - + OpenDialog( dialogData ) - + return } else @@ -236,7 +930,7 @@ void function OnServerSelected( var button ) // this uses semver https://semver.org array serverModVersion = split( NSGetServerRequiredModVersion( serverIndex, i ), "." ) array clientModVersion = split( NSGetModVersionByModName( NSGetServerRequiredModName( serverIndex, i ) ), "." ) - + bool semverFail = false // if server has invalid semver don't bother checking if ( serverModVersion.len() == 3 ) @@ -248,34 +942,38 @@ void function OnServerSelected( var button ) else if ( clientModVersion[ 0 ] != serverModVersion[ 0 ] ) semverFail = true } - + if ( semverFail ) { DialogData dialogData dialogData.header = "#ERROR" - dialogData.message = "Server has mod \"" + NSGetServerRequiredModName( serverIndex, i ) + "\" v" + NSGetServerRequiredModVersion( serverIndex, i ) + " while we have v" + NSGetModVersionByModName( NSGetServerRequiredModName( serverIndex, i ) ) + dialogData.message = "Server has mod \"" + NSGetServerRequiredModName( serverIndex, i ) + "\" v" + NSGetServerRequiredModVersion( serverIndex, i ) + " while we have v" + NSGetModVersionByModName( NSGetServerRequiredModName( serverIndex, i ) ) dialogData.image = $"ui/menu/common/dialog_error" - + #if PC_PROG AddDialogButton( dialogData, "#DISMISS" ) - + AddDialogFooter( dialogData, "#A_BUTTON_SELECT" ) #endif // PC_PROG AddDialogFooter( dialogData, "#B_BUTTON_DISMISS_RUI" ) - + OpenDialog( dialogData ) - + return } } } - + if ( NSServerRequiresPassword( serverIndex ) ) + { + OnCloseServerBrowserMenu() AdvanceMenu( GetMenu( "ConnectWithPasswordMenu" ) ) + } else thread ThreadedAuthAndConnectToServer() } + void function ThreadedAuthAndConnectToServer( string password = "" ) { if ( NSIsAuthenticatingWithServer() ) @@ -283,18 +981,32 @@ void function ThreadedAuthAndConnectToServer( string password = "" ) print( "trying to authenticate with server " + NSGetServerName( file.lastSelectedServer ) + " with password " + password ) NSTryAuthWithServer( file.lastSelectedServer, password ) - - while ( NSIsAuthenticatingWithServer() ) + + ToggleConnectingHUD( true ) + + while ( NSIsAuthenticatingWithServer() && !file.cancelConnection) + { WaitFrame() - + } + + ToggleConnectingHUD( false ) + + if (file.cancelConnection) + { + file.cancelConnection = false + return + } + + file.cancelConnection = false + if ( NSWasAuthSuccessful() ) { bool modsChanged - + array requiredMods for ( int i = 0; i < NSGetServerRequiredModsCount( file.lastSelectedServer ); i++ ) requiredMods.append( NSGetServerRequiredModName( file.lastSelectedServer, i ) ) - + // unload mods we don't need, load necessary ones and reload mods before connecting foreach ( string mod in NSGetModNames() ) { @@ -304,27 +1016,159 @@ void function ThreadedAuthAndConnectToServer( string password = "" ) NSSetModEnabled( mod, requiredMods.contains( mod ) ) } } - + // only actually reload if we need to since the uiscript reset on reload lags hard if ( modsChanged ) ReloadMods() - NSConnectToAuthedServer() } else - { + { DialogData dialogData dialogData.header = "#ERROR" dialogData.message = "Authentication Failed" dialogData.image = $"ui/menu/common/dialog_error" - + #if PC_PROG AddDialogButton( dialogData, "#DISMISS" ) - + AddDialogFooter( dialogData, "#A_BUTTON_SELECT" ) #endif // PC_PROG AddDialogFooter( dialogData, "#B_BUTTON_DISMISS_RUI" ) OpenDialog( dialogData ) } -} \ No newline at end of file +} + +////////////////////////////////////// +// Shadow realm +////////////////////////////////////// +void function SortServerListByName( var button ) +{ + filterDirection.sortingBy = 1 + + int n = file.serversArrayFiltered.len() - 1 + + serverStruct tempServer + + for ( int i = 0; i < n; i++) + { + for ( int j = 0; j < n - 1; j++) + { + if ( file.serversArrayFiltered[ j ].serverName < file.serversArrayFiltered[ j + 1 ].serverName && filterDirection.serverName || file.serversArrayFiltered[ j ].serverName > file.serversArrayFiltered[ j + 1 ].serverName && !filterDirection.serverName) + { + tempServer = file.serversArrayFiltered[ j ] + file.serversArrayFiltered[ j ] = file.serversArrayFiltered[ j + 1 ] + file.serversArrayFiltered[ j + 1 ] = tempServer + } + } + } + + filterDirection.serverName = !filterDirection.serverName + + UpdateShownPage() +} + +void function SortServerListByPlayers( var button ) +{ + filterDirection.sortingBy = 2 + + int n = file.serversArrayFiltered.len() - 1 + + serverStruct tempServer + + for ( int i = 0; i < n; i++) + { + for ( int j = 0; j < n - 1; j++) + { + if ( file.serversArrayFiltered[ j ].serverPlayers < file.serversArrayFiltered[ j + 1 ].serverPlayers && filterDirection.serverPlayers || file.serversArrayFiltered[ j ].serverPlayers > file.serversArrayFiltered[ j + 1 ].serverPlayers && !filterDirection.serverPlayers) + { + tempServer = file.serversArrayFiltered[ j ] + file.serversArrayFiltered[ j ] = file.serversArrayFiltered[ j + 1 ] + file.serversArrayFiltered[ j + 1 ] = tempServer + } + } + } + + filterDirection.serverPlayers = !filterDirection.serverPlayers + + UpdateShownPage() +} + +void function SortServerListByMap( var button ) +{ + filterDirection.sortingBy = 3 + + int n = file.serversArrayFiltered.len() - 1 + + serverStruct tempServer + + for ( int i = 0; i < n; i++) + { + for ( int j = 0; j < n - 1; j++) + { + if ( Localize(file.serversArrayFiltered[ j ].serverMap) < Localize(file.serversArrayFiltered[ j + 1 ].serverMap) && filterDirection.serverMap || Localize(file.serversArrayFiltered[ j ].serverMap) > Localize(file.serversArrayFiltered[ j + 1 ].serverMap) && !filterDirection.serverMap) + { + tempServer = file.serversArrayFiltered[ j ] + file.serversArrayFiltered[ j ] = file.serversArrayFiltered[ j + 1 ] + file.serversArrayFiltered[ j + 1 ] = tempServer + } + } + } + + filterDirection.serverMap = !filterDirection.serverMap + + UpdateShownPage() +} + +void function SortServerListByGamemode( var button ) +{ + filterDirection.sortingBy = 5 + + int n = file.serversArrayFiltered.len() - 1 + + serverStruct tempServer + + for ( int i = 0; i < n; i++) + { + for ( int j = 0; j < n - 1; j++) + { + if ( Localize(file.serversArrayFiltered[ j ].serverGamemode) < Localize(file.serversArrayFiltered[ j + 1 ].serverGamemode) && filterDirection.serverGamemode || Localize(file.serversArrayFiltered[ j ].serverGamemode) > Localize(file.serversArrayFiltered[ j + 1 ].serverGamemode) && !filterDirection.serverGamemode) + { + tempServer = file.serversArrayFiltered[ j ] + file.serversArrayFiltered[ j ] = file.serversArrayFiltered[ j + 1 ] + file.serversArrayFiltered[ j + 1 ] = tempServer + } + } + } + + filterDirection.serverGamemode = !filterDirection.serverGamemode + + UpdateShownPage() +} + +void function SortServerListByLatency( var button ) +{ + filterDirection.sortingBy = 5 + + int n = file.serversArrayFiltered.len() - 1 + + serverStruct tempServer + + for ( int i = 0; i < n; i++) + { + for ( int j = 0; j < n - 1; j++) + { + if ( file.serversArrayFiltered[ j ].serverLatency < file.serversArrayFiltered[ j + 1 ].serverLatency && filterDirection.serverLatency || file.serversArrayFiltered[ j ].serverLatency > file.serversArrayFiltered[ j + 1 ].serverLatency && !filterDirection.serverLatency) + { + tempServer = file.serversArrayFiltered[ j ] + file.serversArrayFiltered[ j ] = file.serversArrayFiltered[ j + 1 ] + file.serversArrayFiltered[ j + 1 ] = tempServer + } + } + } + + filterDirection.serverLatency = !filterDirection.serverLatency + + UpdateShownPage() +} -- cgit v1.2.3 From 8d833a79b4f103abf3394bf1c9bebc071e1f84bd Mon Sep 17 00:00:00 2001 From: F1F7Y Date: Thu, 30 Dec 2021 00:15:40 +0100 Subject: Change panel --- Northstar.Client/mod/resource/ui/menus/server_browser.menu | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Northstar.Client/mod/resource/ui/menus/server_browser.menu b/Northstar.Client/mod/resource/ui/menus/server_browser.menu index b67a2918..feca06fb 100644 --- a/Northstar.Client/mod/resource/ui/menus/server_browser.menu +++ b/Northstar.Client/mod/resource/ui/menus/server_browser.menu @@ -126,7 +126,7 @@ resource/ui/menus/mods_browse.menu xpos -432 zpos 100 - rui "ui/knowledgebase_panel.rpak" + rui "ui/control_options_description.rpak" pin_to_sibling ConnectingAnimation pin_corner_to_sibling TOP_LEFT @@ -162,7 +162,7 @@ resource/ui/menus/mods_browse.menu xpos -462 zpos 100 - rui "ui/knowledgebase_panel.rpak" + rui "ui/control_options_description.rpak" pin_to_sibling ConnectingAnimation pin_corner_to_sibling TOP_LEFT -- cgit v1.2.3 From a109a2d376f61fb92bf9bedffe67713316bcdfae Mon Sep 17 00:00:00 2001 From: Soup-64 <43444191+Soup-64@users.noreply.github.com> Date: Wed, 29 Dec 2021 19:39:06 -0500 Subject: Fix missing respawn grace during EvacEpilogue and Postmatch gamestate Adds in a helper function on top of setting respawn behaviour for adding a grace period before disabling the respawn to fix #30. This also disables respawns during the Postmatch game state, and grace length is controlled by the GAME_EPILOGUE_PLAYER_RESPAWN_LEEWAY constant. --- .../mod/scripts/vscripts/evac/_evac.gnut | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Northstar.CustomServers/mod/scripts/vscripts/evac/_evac.gnut b/Northstar.CustomServers/mod/scripts/vscripts/evac/_evac.gnut index a4f23b85..b861ed9f 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/evac/_evac.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/evac/_evac.gnut @@ -103,11 +103,20 @@ void function EvacEpilogue() if ( canRunEvac ) { - SetRespawnsEnabled( false ) + thread SetRespawnAndWait( false ) thread Evac( GetOtherTeam( winner ), EVAC_INITIAL_WAIT, EVAC_ARRIVAL_TIME, EVAC_WAIT_TIME, EvacEpiloguePlayerCanBoard, EvacEpilogueShouldLeaveEarly, EvacEpilogueCompleted ) } else - thread EvacEpilogueCompleted( null ) // this is hacky but like, this also shouldn't really be hit in normal gameplay + { + thread SetRespawnAndWait( false ) //prevent respawns during the fade to black, should only be an issue if the match is a draw + thread EvacEpilogueCompleted( null ) //this is hacky but like, this also shouldn't really be hit in normal gameplay + } +} + +void function SetRespawnAndWait(bool mode) +{ + wait GAME_EPILOGUE_PLAYER_RESPAWN_LEEWAY + SetRespawnsEnabled( mode ) } bool function EvacEpiloguePlayerCanBoard( entity dropship, entity player ) @@ -386,4 +395,4 @@ void function EvacDropshipKilled( entity dropship, var damageInfo ) player.Die( DamageInfo_GetAttacker( damageInfo ), DamageInfo_GetWeapon( damageInfo ), { damageSourceId = eDamageSourceId.evac_dropship_explosion, scriptType = DF_GIB } ) } } -} \ No newline at end of file +} -- cgit v1.2.3 From 38b3a6efddbe19af38b4d75406f4794d3f8b2c7f Mon Sep 17 00:00:00 2001 From: BobTheBob <32057864+BobTheBob9@users.noreply.github.com> Date: Thu, 30 Dec 2021 02:12:52 +0000 Subject: speedball and dropship crash fixes --- Northstar.Client/mod/scripts/vscripts/ui/panel_mainmenu.nut | 4 ++-- .../mod/scripts/vscripts/gamemodes/sh_gamemode_fw_custom.nut | 2 -- .../mod/scripts/vscripts/gamemodes/_gamemode_speedball.nut | 4 +++- .../mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut | 3 ++- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/Northstar.Client/mod/scripts/vscripts/ui/panel_mainmenu.nut b/Northstar.Client/mod/scripts/vscripts/ui/panel_mainmenu.nut index 25097c6f..ecb34d47 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/panel_mainmenu.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/panel_mainmenu.nut @@ -502,9 +502,9 @@ void function TryUnlockNorthstarButton() // unlock "Launch Northstar" button until you're authed with masterserver, are allowing insecure auth, or 7.5 seconds have passed float time = Time() - while ( Time() < time + 7.5 || GetConVarInt( "ns_has_agreed_to_send_token" ) != NS_AGREED_TO_SEND_TOKEN ) + while ( GetConVarInt( "ns_has_agreed_to_send_token" ) != NS_AGREED_TO_SEND_TOKEN ) { - if ( NSIsMasterServerAuthenticated() || GetConVarBool( "ns_auth_allow_insecure" ) ) + if ( ( NSIsMasterServerAuthenticated() && IsStryderAllowingMP() ) || GetConVarBool( "ns_auth_allow_insecure" ) ) break WaitFrame() diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_fw_custom.nut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_fw_custom.nut index 8c6e3f63..ca238d5d 100644 --- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_fw_custom.nut +++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_fw_custom.nut @@ -13,8 +13,6 @@ void function SHCreateGamemodeFW_Init() void function CreateGamemodeFW() { - //entity e = CreateEntity("npc_turret_mega"); SetAISettingsWrapper( e, "npc_turret_mega_fortwar" ); e.SetOrigin(GetPlayerArray()[0].GetOrigin()); SetTeam(e,3); DispatchSpawn(e) - // we have to manually add the client/shared scripts to scripts.rson atm so we need to prevent compile errors when they aren't included // best way to do this is to just ignore this whole block for now and wait until we don't have to add them manually diff --git a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_speedball.nut b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_speedball.nut index cef0af6b..22c660d8 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_speedball.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_speedball.nut @@ -103,7 +103,9 @@ void function DropFlag() file.flag.ClearParent() file.flag.SetAngles( < 0, 0, 0 > ) SetGlobalNetEnt( "flagCarrier", file.flag ) - EmitSoundOnEntityOnlyToPlayer( file.flagCarrier, file.flagCarrier, "UI_CTF_1P_FlagDrop" ) + + if ( IsValid( file.flagCarrier ) ) + EmitSoundOnEntityOnlyToPlayer( file.flagCarrier, file.flagCarrier, "UI_CTF_1P_FlagDrop" ) foreach ( entity player in GetPlayerArray() ) MessageToPlayer( player, eEventNotifications.SPEEDBALL_FlagDropped, file.flagCarrier ) diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut b/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut index 78dec3d1..d3b4cd7e 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut @@ -125,6 +125,8 @@ void function EndIntroWhenFinished() void function SpawnPlayerIntoDropship( entity player ) { + player.EndSignal( "OnDestroy" ) + if ( IsAlive( player ) ) player.Die() // kill them so we don't have any issues respawning them later @@ -148,7 +150,6 @@ void function SpawnPlayerIntoDropship( entity player ) WaitFrame() player.EndSignal( "OnDeath" ) - player.EndSignal( "OnDestroy" ) // find the player's dropship and seat array teamDropships -- cgit v1.2.3 From d90fccb4cef95c2809cabab8454c22121c91efef Mon Sep 17 00:00:00 2001 From: Barichello Date: Wed, 29 Dec 2021 23:37:07 -0300 Subject: Fix #17 --- .../mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut b/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut index d3b4cd7e..8e624c14 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/_classic_mp_dropship_intro.gnut @@ -180,6 +180,7 @@ void function SpawnPlayerIntoDropship( entity player ) // respawn player and holster their weapons so they aren't out player.RespawnPlayer( null ) + HolsterAndDisableWeapons(player) player.DisableWeaponViewModel() // hide hud and fade screen out from black @@ -187,7 +188,7 @@ void function SpawnPlayerIntoDropship( entity player ) ScreenFadeFromBlack( player, 0.5, 0.5 ) // faction leaders are done clientside, spawn them here Remote_CallFunction_NonReplay( player, "ServerCallback_SpawnFactionCommanderInDropship", playerDropship.dropship.GetEncodedEHandle(), file.introStartTime ) - + // do firstperson sequence FirstPersonSequenceStruct idleSequence idleSequence.firstPersonAnim = DROPSHIP_IDLE_ANIMS_POV[ playerDropshipIndex ] @@ -229,6 +230,7 @@ void function PlayerJumpsFromDropship( entity player ) // show weapon viewmodel and hud and let them move again player.MovementEnable() player.EnableWeaponViewModel() + DeployAndEnableWeapons(player) RemoveCinematicFlag( player, CE_FLAG_CLASSIC_MP_SPAWNING ) } }) -- cgit v1.2.3 From ba9988a1be3baab498e7dd9dbaf191266653481a Mon Sep 17 00:00:00 2001 From: BobTheBob <32057864+BobTheBob9@users.noreply.github.com> Date: Thu, 30 Dec 2021 02:43:37 +0000 Subject: remove unnecessary files from prs --- _burnmeter.gnut | 441 ----------------------------------------------------- _gamemode_ps.nut | 27 ---- _gamemode_tdm.nut | 31 ---- _gamemode_ttdm.nut | 87 ----------- 4 files changed, 586 deletions(-) delete mode 100644 _burnmeter.gnut delete mode 100644 _gamemode_ps.nut delete mode 100644 _gamemode_tdm.nut delete mode 100644 _gamemode_ttdm.nut diff --git a/_burnmeter.gnut b/_burnmeter.gnut deleted file mode 100644 index 3eb6bda6..00000000 --- a/_burnmeter.gnut +++ /dev/null @@ -1,441 +0,0 @@ -untyped - -global function BurnMeter_Init -global function ForceSetGlobalBurncardOverride -global function GetSelectedBurncardRefFromWeaponOrPlayer -global function RunBurnCardUseFunc -global function UseBurnCardWeapon -global function UseBurnCardWeaponInCriticalSection -global function BurnMeter_GiveRewardDirect -global function GetBurnCardWeaponSkin -global function InitBurnMeterPersistentData - -const float PHASE_REWIND_LENGTH = 2.0 -// taken from wraith portal in apex, assuming it's the same as tf2's -const float PHASE_REWIND_PATH_SNAPSHOT_INTERVAL = 0.1 -const int PHASE_REWIND_MAX_SNAPSHOTS = int( PHASE_REWIND_LENGTH / PHASE_REWIND_PATH_SNAPSHOT_INTERVAL ) - -const float AMPED_WEAPONS_LENGTH = 30.0 - -const int MAPHACK_PULSE_COUNT = 4 -const float MAPHACK_PULSE_DELAY = 2.0 - -struct { - string forcedGlobalBurncardOverride = "" -} file - -void function BurnMeter_Init() -{ - // turret precaches - // do we have to cache these on client? release builds sure don't - PrecacheModel( Dev_GetAISettingAssetByKeyField_Global( "npc_turret_sentry_burn_card_ap", "DefaultModelName" ) ) - PrecacheModel( Dev_GetAISettingAssetByKeyField_Global( "npc_turret_sentry_burn_card_at", "DefaultModelName" ) ) - - // setup burncard use funcs - BurnReward_GetByRef( "burnmeter_amped_weapons" ).rewardAvailableCallback = PlayerUsesAmpedWeaponsBurncard - BurnReward_GetByRef( "burnmeter_smart_pistol" ).rewardAvailableCallback = PlayerUsesSmartPistolBurncard - BurnReward_GetByRef( "burnmeter_emergency_battery" ).rewardAvailableCallback = PlayerUsesBatteryBurncard - BurnReward_GetByRef( "burnmeter_radar_jammer" ).rewardAvailableCallback = PlayerUsesRadarJammerBurncard - BurnReward_GetByRef( "burnmeter_maphack" ).rewardAvailableCallback = PlayerUsesMaphackBurncard - BurnReward_GetByRef( "burnmeter_phase_rewind" ).rewardAvailableCallback = PlayerUsesPhaseRewindBurncard - - // these ones aren't so important, they're either for fd ( unsupported rn ) or unused - //BurnReward_GetByRef( "burnmeter_harvester_shield" ).rewardAvailableCallback = - BurnReward_GetByRef( "burnmeter_rodeo_grenade" ).rewardAvailableCallback = PlayerUsesRodeoGrenadeBurncard - BurnReward_GetByRef( "burnmeter_nuke_titan" ).rewardAvailableCallback = PlayerUsesNukeTitanBurncard // unused in vanilla, fun though - - // setup player callbacks - AddCallback_GameStateEnter( eGameState.Playing, InitBurncardsForIntroPlayers ) - AddCallback_OnClientConnected( InitBurncardsForLateJoiner ) - - AddCallback_OnPlayerRespawned( StartPhaseRewindLifetime ) - AddCallback_OnTitanBecomesPilot( RemoveAmpedWeaponsForTitanPilot ) - - // necessary signals - RegisterSignal( "StopAmpedWeapons" ) -} - -void function ForceSetGlobalBurncardOverride( string ref ) -{ - file.forcedGlobalBurncardOverride = ref -} - -string function GetSelectedBurncardRefFromWeaponOrPlayer( entity weapon, entity player ) -{ - // determine the burncard we're using - // in actual gameplay, this will always be the player's selected burncard - // however, if we want to manually give burncards and such, we want to make sure they'll still work - // so some extra work goes into this - - string ref = GetSelectedBurnCardRef( player ) - - if ( file.forcedGlobalBurncardOverride.len() > 0 ) - ref = file.forcedGlobalBurncardOverride - - if ( IsValid( weapon ) ) - { - // determine via weapon mods, this assumes weapon mod names are the same as burn refs, which works in practice but is a bit weird - // this does crash with the burnmeter_doublexp mod, but who cares, it doesn't get hit normally - if ( weapon.GetWeaponClassName() == "mp_ability_burncardweapon" ) - { - foreach ( string mod in weapon.GetMods() ) - if ( mod.find( "burnmeter_" ) == 0 ) - return mod - } - // determine via weapon name in the case of stuff like holopilot etc - else - { - // unfortunately, we have to hardcode this, we don't have a way of getting refs directly from weapons other than the burncard weapon - // this should be modular at some point, wish we could just iterate over burncards and find ones with the current weapon, but this isn't possible - switch ( weapon.GetWeaponClassName() ) - { - case "mp_ability_holopilot_nova": - return "burnmeter_holopilot_nova" - - case "mp_weapon_arc_trap": - return "burnmeter_arc_trap" - - case "mp_weapon_frag_drone": - return "burnmeter_ticks" - - case "mp_weapon_hard_cover": - return "burnmeter_hard_cover" - - case "mp_ability_turretweapon": - // turret has 2 burncards, antititan and antipilot - if( weapon.HasMod( "burnmeter_at_turret_weapon" ) || weapon.HasMod( "burnmeter_at_turret_weapon_inf" ) ) - return "burnmeter_at_turret_weapon" - else - return "burnmeter_ap_turret_weapon" - - // note: cloak and stim both have burn_card_weapon_mod mods, but they aren't used and don't call burncard code at all, likely for tf1 infinite stim/cloak burncards? - - default: - print( "tried to use unknown burncard weapon " + weapon.GetWeaponClassName() ) - return "burnmeter_amped_weapons" - } - } - } - - return ref -} - -void function InitPlayerBurncards( entity player ) -{ - string ref = GetSelectedBurncardRefFromWeaponOrPlayer( null, player ) - BurnReward reward = BurnReward_GetByRef( ref ) - player.SetPlayerNetInt( TOP_INVENTORY_ITEM_BURN_CARD_ID, reward.id ) - - if ( IsAlive( player ) ) - thread PhaseRewindLifetime( player ) -} - -void function InitBurncardsForIntroPlayers() -{ - // gotta do this, since sh_burnmeter uses this netint - foreach ( entity player in GetPlayerArray() ) - InitPlayerBurncards( player ) -} - -void function InitBurncardsForLateJoiner( entity player ) -{ - // gotta do this, since sh_burnmeter uses this netint - if ( GetGameState() > eGameState.Prematch ) - InitPlayerBurncards( player ) -} - -void function StartPhaseRewindLifetime( entity player ) -{ - thread PhaseRewindLifetime( player ) -} - -void function PhaseRewindLifetime( entity player ) -{ - player.EndSignal( "OnDestroy" ) - player.EndSignal( "OnDeath" ) - - OnThreadEnd( function() : ( player ) - { - player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions.clear() - }) - - while ( true ) - { - PhaseRewindData rewindData - rewindData.origin = player.GetOrigin() - rewindData.angles = player.GetAngles() - rewindData.velocity = player.GetVelocity() - rewindData.wasInContextAction = player.ContextAction_IsActive() - rewindData.wasCrouched = player.IsCrouched() - - if ( player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions.len() >= PHASE_REWIND_MAX_SNAPSHOTS ) - { - // shift all snapshots left - for ( int i = 0; i < PHASE_REWIND_MAX_SNAPSHOTS - 1; i++ ) - player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions[ i ] = player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions[ i + 1 ] - - player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions[ PHASE_REWIND_MAX_SNAPSHOTS - 1 ] = rewindData - } - else - player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions.append( rewindData ) - - wait PHASE_REWIND_PATH_SNAPSHOT_INTERVAL - } -} - -void function RunBurnCardUseFunc( entity player, string itemRef ) -{ - void functionref( entity ) ornull func = BurnReward_GetByRef( itemRef ).rewardAvailableCallback - if ( func != null ) - ( expect void functionref( entity ) ( func ) )( player ) -} - -void function UseBurnCardWeapon( entity weapon, entity player ) -{ - string ref = GetSelectedBurncardRefFromWeaponOrPlayer( weapon, player ) - - Remote_CallFunction_Replay( player, "ServerCallback_RewardUsed", BurnReward_GetByRef( ref ).id ) - RunBurnCardUseFunc( player, ref ) - - // dont remove in RunBurnCardUseFunc because it can be called in non-burn_card_weapon_mod contexts - // TODO: currently not sure how burncards can be stacked ( max clipcount for all burncards is 1, so can't just set that ) - // if this gets figured out, add a conditional check here to prevent removes if they've got burncards left - if ( PlayerEarnMeter_IsRewardAvailable( player ) ) - PlayerEarnMeter_SetRewardUsed( player ) - - player.TakeWeapon( BurnReward_GetByRef( ref ).weaponName ) -} - -void function UseBurnCardWeaponInCriticalSection( entity weapon, entity ownerPlayer ) -{ - // ignoring critical section stuff, assuming it was necessary in tf1 where burncards were part of inventory, but not here - UseBurnCardWeapon( weapon, ownerPlayer ) -} - -void function BurnMeter_GiveRewardDirect( entity player, string itemRef ) -{ - -} - -int function GetBurnCardWeaponSkin( entity weapon ) -{ - return GetBoostSkin( GetSelectedBurncardRefFromWeaponOrPlayer( weapon, weapon.GetOwner() ) ) -} - -// stub -void function InitBurnMeterPersistentData( entity player ) -{} - - -// burncard use funcs - -void function PlayerUsesAmpedWeaponsBurncard( entity player ) -{ - thread PlayerUsesAmpedWeaponsBurncardThreaded( player ) -} - -void function PlayerUsesAmpedWeaponsBurncardThreaded( entity player ) -{ - array weapons = player.GetMainWeapons() - //weapons.extend( player.GetOffhandWeapons() ) // idk? unsure of vanilla behaviour here - foreach ( entity weapon in weapons ) - { - weapon.RemoveMod( "silencer" ) // both this and the burnmod will override firing fx, if a second one overrides this we crash - foreach ( string mod in GetWeaponBurnMods( weapon.GetWeaponClassName() ) ) - { - // catch incompatibilities just in case - try - { - weapon.AddMod( mod ) - } - catch( ex ) - { - weapons.removebyvalue( weapon ) - } - } - - // needed to display amped weapon time left - weapon.SetScriptFlags0( weapon.GetScriptFlags0() | WEAPONFLAG_AMPED ) - weapon.SetScriptTime0( Time() + AMPED_WEAPONS_LENGTH ) - } - - wait AMPED_WEAPONS_LENGTH - - // note: weapons may have been destroyed or picked up by other people by this point, so need to verify this - foreach ( entity weapon in weapons ) - { - if ( !IsValid( weapon ) ) - continue - - foreach ( string mod in GetWeaponBurnMods( weapon.GetWeaponClassName() ) ) - weapon.RemoveMod( mod ) - - weapon.SetScriptFlags0( weapon.GetScriptFlags0() & ~WEAPONFLAG_AMPED ) - } -} - -void function RemoveAmpedWeaponsForTitanPilot( entity player, entity titan ) -{ - foreach ( entity weapon in player.GetMainWeapons() ) - foreach ( string mod in GetWeaponBurnMods( weapon.GetWeaponClassName() ) ) - weapon.RemoveMod( mod ) -} - -void function PlayerUsesSmartPistolBurncard( entity player ) -{ - // take secondary weapon - array sidearms = player.GetMainWeapons() - if ( sidearms.len() > 1 ) - player.TakeWeaponNow( sidearms[ 1 ].GetWeaponClassName() ) // take secondary weapon - - player.GiveWeapon( "mp_weapon_smart_pistol" ) - player.SetActiveWeaponByName( "mp_weapon_smart_pistol" ) - - // do we need to track the player losing smart pistol, then give their old weapon back? idk not implementing for now, check later -} - -void function PlayerUsesBatteryBurncard( entity player ) -{ - Rodeo_GiveBatteryToPlayer( player ) -} - -void function PlayerUsesRadarJammerBurncard( entity player ) -{ - foreach ( entity otherPlayer in GetPlayerArray() ) - { - MessageToPlayer( otherPlayer, eEventNotifications.BurnMeter_RadarJammerUsed, player ) - - if ( otherPlayer.GetTeam() != player.GetTeam() ) - StatusEffect_AddTimed( otherPlayer, eStatusEffect.minimap_jammed, 1.0, RADAR_JAM_TIME, RADAR_JAM_TIME ) - } -} - -void function PlayerUsesMaphackBurncard( entity player ) -{ - thread PlayerUsesMaphackBurncardThreaded( player ) -} - -void function PlayerUsesMaphackBurncardThreaded( entity player ) -{ - player.EndSignal( "OnDestroy" ) - player.EndSignal( "OnDeath" ) - - // todo: potentially look into ScanMinimap in _passives for doing this better? boost is pretty likely based off it pretty heavily - for ( int i = 0; i < MAPHACK_PULSE_COUNT; i++ ) - { - EmitSoundOnEntityOnlyToPlayer( player, player, "Burn_Card_Map_Hack_Radar_Pulse_V1_1P" ) - array aliveplayers = GetPlayerArray() - foreach ( entity otherPlayer in GetPlayerArray() ) - { - Remote_CallFunction_Replay( otherPlayer, "ServerCallback_SonarPulseFromPosition", player.GetOrigin().x, player.GetOrigin().y, player.GetOrigin().z, SONAR_GRENADE_RADIUS ) - - if ( otherPlayer.GetTeam() != player.GetTeam() && aliveplayers.find(otherPlayer) != -1 && aliveplayers.find(player) != -1 ) - { - StatusEffect_AddTimed( otherPlayer, eStatusEffect.maphack_detected, 1.0, MAPHACK_PULSE_DELAY / 2, 0.0 ) - SonarStart( otherPlayer, player.GetOrigin(), player.GetTeam(), player ) - IncrementSonarPerTeam( player.GetTeam() ) - } - } - wait MAPHACK_PULSE_DELAY - foreach ( entity otherPlayer in GetPlayerArray() ) { - if ( otherPlayer.GetTeam() != player.GetTeam() && aliveplayers.find(otherPlayer) != -1 && aliveplayers.find(player) != -1 ) { - SonarEnd (otherPlayer, player.GetTeam() ) - DecrementSonarPerTeam( player.GetTeam() ) - } - } - } -} - -void function PlayerUsesPhaseRewindBurncard( entity player ) -{ - thread PlayerUsesPhaseRewindBurncardThreaded( player ) -} - -void function PlayerUsesPhaseRewindBurncardThreaded( entity player ) -{ - player.EndSignal( "OnDestroy" ) - player.EndSignal( "OnDeath" ) - - entity mover = CreateScriptMover( player.GetOrigin(), player.GetAngles() ) - player.SetParent( mover, "REF" ) - - OnThreadEnd( function() : ( player, mover ) - { - CancelPhaseShift( player ) - player.DeployWeapon() - player.SetPredictionEnabled( true ) - player.ClearParent() - ViewConeFree( player ) - mover.Destroy() - }) - - array positions = clone player.p.burnCardPhaseRewindStruct.phaseRetreatSavedPositions - - ViewConeZero( player ) - player.HolsterWeapon() - player.SetPredictionEnabled( false ) - PhaseShift( player, 0.0, positions.len() * PHASE_REWIND_PATH_SNAPSHOT_INTERVAL * 1.5 ) - - for ( int i = positions.len() - 1; i > -1; i-- ) - { - mover.NonPhysicsMoveTo( positions[ i ].origin, PHASE_REWIND_PATH_SNAPSHOT_INTERVAL, 0, 0 ) - mover.NonPhysicsRotateTo( positions[ i ].angles, PHASE_REWIND_PATH_SNAPSHOT_INTERVAL, 0, 0 ) - wait PHASE_REWIND_PATH_SNAPSHOT_INTERVAL - } - - // this isn't vanilla but it's cool lol, should prolly remove it tho - player.SetVelocity( -positions[ positions.len() - 1 ].velocity ) -} - -void function PlayerUsesNukeTitanBurncard( entity player ) -{ - thread PlayerUsesNukeBurncardThreaded( player ) -} - -void function PlayerUsesNukeBurncardThreaded( entity player ) -{ - // if this is given manually ( i.e. not the equipped burnreward in inventory ), this will run at bad times - // so do this check here, yes, this will cause people to lose their cards and get nothing, but better than free titan regens - if ( !BurnMeterPlayer_CanUseReward( player, BurnReward_GetByRef( "burnmeter_nuke_titan" ) ) ) - return - - float ownedFrac = PlayerEarnMeter_GetOwnedFrac( player ) - - // use player's titan loadout, but with warpfall so faster and no dome - TitanLoadoutDef titanLoadout = GetTitanLoadoutForPlayer( player ) - titanLoadout.passive3 = "pas_warpfall" - - thread CreateTitanForPlayerAndHotdrop( player, GetTitanReplacementPoint( player, false ) ) - - entity titan = player.GetPetTitan() - SetTeam( titan, TEAM_UNASSIGNED ) // make it so you can kill yourself lol - DoomTitan( titan ) - NPC_SetNuclearPayload( titan ) - // this should get run after the vanilla set_usable's event, so titan is never embarkable - // embarking a titan in this state WILL kill the server so uhh, pretty bad - AddAnimEvent( titan, "set_usable", void function( entity titan ) { titan.UnsetUsable() } ) - - titan.WaitSignal( "TitanHotDropComplete" ) - AutoTitan_SelfDestruct( titan ) - - while ( PlayerEarnMeter_GetMode( player ) == eEarnMeterMode.PET ) - WaitFrame() - - // restore original earnmeter values, no way to set earned that's exposed unfortunately - PlayerEarnMeter_SetOwnedFrac( player, ownedFrac ) -} - -void function PlayerUsesRodeoGrenadeBurncard( entity player ) -{ - player.SetPlayerNetInt( "numSuperRodeoGrenades", player.GetPlayerNetInt( "numSuperRodeoGrenades" ) + 1 ) -} - -// unused burncard that's mentioned in a few areas and has a validiation function in sh_burnmeter ( BurnMeter_SummonReaperCanUse ), thought it'd be neat to add it -void function PlayerUsesReaperfallBurncard( entity player ) -{ - Point spawnpoint = GetTitanReplacementPoint( player, false ) - entity reaper = CreateSuperSpectre( player.GetTeam(), spawnpoint.origin, spawnpoint.angles ) - DispatchSpawn( reaper ) - - thread SuperSpectre_WarpFall( reaper ) -} \ No newline at end of file diff --git a/_gamemode_ps.nut b/_gamemode_ps.nut deleted file mode 100644 index 7eec7c89..00000000 --- a/_gamemode_ps.nut +++ /dev/null @@ -1,27 +0,0 @@ -global function GamemodePs_Init - -void function GamemodePs_Init() -{ - Riff_ForceTitanAvailability( eTitanAvailability.Never ) - - AddCallback_OnPlayerKilled( GiveScoreForPlayerKill ) - ScoreEvent_SetupEarnMeterValuesForMixedModes() - SetTimeoutWinnerDecisionFunc( CheckScoreForDraw ) - -} - -void function GiveScoreForPlayerKill( entity victim, entity attacker, var damageInfo ) -{ - if ( victim != attacker && victim.IsPlayer() && attacker.IsPlayer() || GetGameState() != eGameState.Playing ) - AddTeamScore( attacker.GetTeam(), 1 ) -} - -int function CheckScoreForDraw() -{ - if (GameRules_GetTeamScore(TEAM_IMC) > GameRules_GetTeamScore(TEAM_MILITIA)) - return TEAM_IMC - else if (GameRules_GetTeamScore(TEAM_MILITIA) > GameRules_GetTeamScore(TEAM_IMC)) - return TEAM_MILITIA - - return TEAM_UNASSIGNED -} \ No newline at end of file diff --git a/_gamemode_tdm.nut b/_gamemode_tdm.nut deleted file mode 100644 index ba180790..00000000 --- a/_gamemode_tdm.nut +++ /dev/null @@ -1,31 +0,0 @@ -global function GamemodeTdm_Init -global function RateSpawnpoints_Directional - -void function GamemodeTdm_Init() -{ - AddCallback_OnPlayerKilled( GiveScoreForPlayerKill ) - ScoreEvent_SetupEarnMeterValuesForMixedModes() - SetTimeoutWinnerDecisionFunc( CheckScoreForDraw ) -} - -void function GiveScoreForPlayerKill( entity victim, entity attacker, var damageInfo ) -{ - if ( victim != attacker && victim.IsPlayer() && attacker.IsPlayer() || GetGameState() != eGameState.Playing ) - AddTeamScore( attacker.GetTeam(), 1 ) -} - -void function RateSpawnpoints_Directional( int checkclass, array spawnpoints, int team, entity player ) -{ - // temp - RateSpawnpoints_Generic( checkclass, spawnpoints, team, player ) -} - -int function CheckScoreForDraw() -{ - if (GameRules_GetTeamScore(TEAM_IMC) > GameRules_GetTeamScore(TEAM_MILITIA)) - return TEAM_IMC - else if (GameRules_GetTeamScore(TEAM_MILITIA) > GameRules_GetTeamScore(TEAM_IMC)) - return TEAM_MILITIA - - return TEAM_UNASSIGNED -} \ No newline at end of file diff --git a/_gamemode_ttdm.nut b/_gamemode_ttdm.nut deleted file mode 100644 index c72fcb0d..00000000 --- a/_gamemode_ttdm.nut +++ /dev/null @@ -1,87 +0,0 @@ -global function GamemodeTTDM_Init - -const float TTDMIntroLength = 15.0 - -void function GamemodeTTDM_Init() -{ - Riff_ForceSetSpawnAsTitan( eSpawnAsTitan.Always ) - Riff_ForceTitanExitEnabled( eTitanExitEnabled.Never ) - TrackTitanDamageInPlayerGameStat( PGS_ASSAULT_SCORE ) - ScoreEvent_SetupEarnMeterValuesForMixedModes() - SetLoadoutGracePeriodEnabled( false ) - - ClassicMP_SetCustomIntro( TTDMIntroSetup, TTDMIntroLength ) - ClassicMP_ForceDisableEpilogue( true ) - SetTimeoutWinnerDecisionFunc( CheckScoreForDraw ) - - AddCallback_OnPlayerKilled( AddTeamScoreForPlayerKilled ) // dont have to track autotitan kills since you cant leave your titan in this mode - - // probably needs scoreevent earnmeter values -} - -void function TTDMIntroSetup() -{ - // this should show intermission cam for 15 sec in prematch, before spawning players as titans - AddCallback_GameStateEnter( eGameState.Prematch, TTDMIntroStart ) - AddCallback_OnClientConnected( TTDMIntroShowIntermissionCam ) -} - -void function TTDMIntroStart() -{ - thread TTDMIntroStartThreaded() -} - -void function TTDMIntroStartThreaded() -{ - ClassicMP_OnIntroStarted() - - foreach ( entity player in GetPlayerArray() ) - TTDMIntroShowIntermissionCam( player ) - - wait TTDMIntroLength - - ClassicMP_OnIntroFinished() -} - -void function TTDMIntroShowIntermissionCam( entity player ) -{ - if ( GetGameState() != eGameState.Prematch ) - return - - thread PlayerWatchesTTDMIntroIntermissionCam( player ) -} - -void function PlayerWatchesTTDMIntroIntermissionCam( entity player ) -{ - ScreenFadeFromBlack( player ) - - entity intermissionCam = GetEntArrayByClass_Expensive( "info_intermission" )[ 0 ] - - // the angle set here seems sorta inconsistent as to whether it actually works or just stays at 0 for some reason - player.SetObserverModeStaticPosition( intermissionCam.GetOrigin() ) - player.SetObserverModeStaticAngles( intermissionCam.GetAngles() ) - player.StartObserverMode( OBS_MODE_STATIC_LOCKED ) - - wait TTDMIntroLength - - RespawnAsTitan( player, false ) - TryGameModeAnnouncement( player ) -} - -void function AddTeamScoreForPlayerKilled( entity victim, entity attacker, var damageInfo ) -{ - if ( victim == attacker || !victim.IsPlayer() || !attacker.IsPlayer() || GetGameState() != eGameState.Playing ) - return - - AddTeamScore( GetOtherTeam( victim.GetTeam() ), 1 ) -} - -int function CheckScoreForDraw() -{ - if (GameRules_GetTeamScore(TEAM_IMC) > GameRules_GetTeamScore(TEAM_MILITIA)) - return TEAM_IMC - else if (GameRules_GetTeamScore(TEAM_MILITIA) > GameRules_GetTeamScore(TEAM_IMC)) - return TEAM_MILITIA - - return TEAM_UNASSIGNED -} \ No newline at end of file -- cgit v1.2.3 From bde589963e9030bdae5bfad1cbf068c0ad6e078a Mon Sep 17 00:00:00 2001 From: BobTheBob <32057864+BobTheBob9@users.noreply.github.com> Date: Thu, 30 Dec 2021 02:48:47 +0000 Subject: use GetPrivateMatchModes rather than hardcoding serverbrowser modes --- .../scripts/vscripts/ui/menu_ns_serverbrowser.nut | 43 +--------------------- 1 file changed, 1 insertion(+), 42 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 dd2f8864..6dcdabd8 100644 --- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut +++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut @@ -83,47 +83,6 @@ bool function floatCompareInRange(float arg1, float arg2, float tolerance) } - -// Hard coded for now -array function GetNorthstarGamemodes() -{ - array modes - - //modes.append( "#PL_aitdm" ) - modes.append( "#PL_pilot_hunter" ) - modes.append( "#PL_hardpoint" ) - //modes.append( "#PL_attrition" ) - modes.append( "#PL_capture_the_flag" ) - modes.append( "#PL_last_titan_standing" ) - modes.append( "#PL_pilot_skirmish" ) - modes.append( "#PL_live_fire" ) - modes.append( "#PL_marked_for_death" ) - modes.append( "#PL_titan_brawl" ) - //modes.append( "#PL_fd_easy" ) - //modes.append( "#PL_fd_normal" ) - //modes.append( "#PL_fd_hard" ) - //modes.append( "#PL_fd_master" ) - //modes.append( "#PL_fd_insane" ) - modes.append( "#PL_ffa" ) - modes.append( "#PL_fra" ) - modes.append( "#PL_coliseum" ) - modes.append( "#PL_aegis_titan_brawl" ) - modes.append( "#PL_titan_brawl_turbo" ) - modes.append( "#PL_aegis_last_titan_standing" ) - modes.append( "#PL_turbo_last_titan_standing" ) - modes.append( "#PL_rocket_arena" ) - modes.append( "#PL_all_holopilot" ) - modes.append( "#PL_gg" ) - modes.append( "#PL_tt" ) - modes.append( "#PL_inf" ) - modes.append( "#PL_kr" ) - modes.append( "#PL_fastball" ) - modes.append( "#GAMEMODE_hs" ) - modes.append( "#GAMEMODE_ctf_comp" ) - - - return modes -} //////////////////////////// // Init //////////////////////////// @@ -154,7 +113,7 @@ void function InitServerBrowserMenu() Hud_DialogList_AddListItem( Hud_GetChild( file.menu, "SwtBtnSelectMap" ) , map, string( enum_ ) ) - filterArguments.filterGamemodes = GetNorthstarGamemodes() + filterArguments.filterGamemodes = GetPrivateMatchModes() filterArguments.filterGamemodes.insert(0, "SWITCH_ANY") // GetGameModeDisplayName( mode ) requires server talk even if it can be entirely client side -- cgit v1.2.3