mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Add setting for allowing non-English name in player list (#2556)
Non-vanilla server may have player name other than English, for example Chinese server can have player name in Chinese. This setting allow MCC to display those non-English name in the player list.
This commit is contained in:
parent
ac65482296
commit
a8200b6e14
5 changed files with 2006 additions and 1273 deletions
|
|
@ -2967,7 +2967,7 @@ namespace MinecraftClient
|
||||||
public void OnPlayerJoin(PlayerInfo player)
|
public void OnPlayerJoin(PlayerInfo player)
|
||||||
{
|
{
|
||||||
//Ignore placeholders eg 0000tab# from TabListPlus
|
//Ignore placeholders eg 0000tab# from TabListPlus
|
||||||
if (!ChatBot.IsValidName(player.Name))
|
if (Config.Main.Advanced.IgnoreInvalidPlayerName && !ChatBot.IsValidName(player.Name))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (player.Name == username)
|
if (player.Name == username)
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load diff
|
|
@ -843,4 +843,7 @@ If the connection to the Minecraft game server is blocked by the firewall, set E
|
||||||
<data name="ChatBot.WebSocketBot.DebugMode" xml:space="preserve">
|
<data name="ChatBot.WebSocketBot.DebugMode" xml:space="preserve">
|
||||||
<value>This setting is for developers who are developing a library that uses this chat bot to remotely execute procedures/commands/functions.</value>
|
<value>This setting is for developers who are developing a library that uses this chat bot to remotely execute procedures/commands/functions.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="Main.Advanced.ignore_invalid_playername" xml:space="preserve">
|
||||||
|
<value>Ignore invalid player name</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
|
|
@ -617,6 +617,9 @@ namespace MinecraftClient
|
||||||
[TomlInlineComment("$Main.Advanced.MinTerminalHeight$")]
|
[TomlInlineComment("$Main.Advanced.MinTerminalHeight$")]
|
||||||
public int MinTerminalHeight = 10;
|
public int MinTerminalHeight = 10;
|
||||||
|
|
||||||
|
[TomlInlineComment("$Main.Advanced.ignore_invalid_playername$")]
|
||||||
|
public bool IgnoreInvalidPlayerName = true;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Load login/password using an account alias
|
/// Load login/password using an account alias
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
||||||
|
|
@ -596,6 +596,16 @@ Coordinate = { x = 145, y = 64, y = 2045 }
|
||||||
|
|
||||||
**A movement speed higher than 2 may be considered cheating by some plugins.**
|
**A movement speed higher than 2 may be considered cheating by some plugins.**
|
||||||
|
|
||||||
|
#### `IgnoreInvalidPlayerName`
|
||||||
|
|
||||||
|
- **Description:**
|
||||||
|
|
||||||
|
Minecraft player name can only consist of English letters, numbers, and underscore symbols. Other name will be considered as invalid and ignored by default.
|
||||||
|
|
||||||
|
- **Type:** `boolean`
|
||||||
|
|
||||||
|
- **Default:** `true`
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
### Account List section
|
### Account List section
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue