Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Select & show preferred skill level when making a game #598

Merged
merged 14 commits into from
Jan 3, 2025
7 changes: 4 additions & 3 deletions DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,11 @@
public void SetInfo(GenericHostedGame game)
{
// we don't have the ID of a map here
string translatedMapName = string.IsNullOrEmpty(game.Map)
string translatedMapName = string.IsNullOrEmpty(game.Map)
? "Unknown".L10N("Client:Main:Unknown") : mapLoader.TranslatedMapNames.ContainsKey(game.Map)
? mapLoader.TranslatedMapNames[game.Map] : game.Map;

string translatedGameModeName = string.IsNullOrEmpty(game.GameMode)
string translatedGameModeName = string.IsNullOrEmpty(game.GameMode)
? "Unknown".L10N("Client:Main:Unknown") : game.GameMode.L10N($"INI:GameModes:{game.GameMode}:UIName", notify: false);

lblGameMode.Text = Renderer.GetStringWithLimitedWidth("Game mode:".L10N("Client:Main:GameInfoGameMode") + " " + Renderer.GetSafeString(translatedGameModeName, lblGameMode.FontIndex),
Expand Down Expand Up @@ -143,7 +143,8 @@
lblPlayerNames[i].Visible = false;
}

lblGameDifficulty.Text = "Preferred Skill Level:".L10N("Client:Main:GameInfoDifficulty") + " " + OnlineGameDifficultyOptions[game.GameDifficulty];
lblGameDifficulty.Text = "Preferred Skill Level: ".L10N("Client:Main:GameInfoDifficulty")

Check warning on line 146 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (Ares)

The value of key Client:Main:GameInfoDifficulty should not have leading or trailing whitespace.

Check warning on line 146 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (TS)

The value of key Client:Main:GameInfoDifficulty should not have leading or trailing whitespace.

Check warning on line 146 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (YR)

The value of key Client:Main:GameInfoDifficulty should not have leading or trailing whitespace.
+ " ".L10N($"INI:ClientDefinitions:Difficulty:{game.GameDifficulty}");

Check warning on line 147 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (Ares)

The value of an INI translation should not be a compile-time string.

Check warning on line 147 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (TS)

The value of an INI translation should not be a compile-time string.

Check warning on line 147 in DXMainClient/DXGUI/Multiplayer/GameInformationPanel.cs

View workflow job for this annotation

GitHub Actions / build-clients (YR)

The value of an INI translation should not be a compile-time string.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

huh?

}

public void ClearInfo()
Expand Down
Loading