1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-21 00:19:29 +02:00

fix player translation

This commit is contained in:
Laserlicht
2024-10-07 18:37:07 +02:00
parent 2d4c0778b0
commit 1c6eaf6336

View File

@ -141,7 +141,12 @@ void CServerHandler::resetStateForLobby(EStartMode mode, ESelectionScreen screen
if(!playerNames.empty()) //if have custom set of player names - use it
localPlayerNames = playerNames;
else
localPlayerNames.push_back(settings["general"]["playerName"].String());
{
std::string playerName = settings["general"]["playerName"].String();
if(playerName == "Player")
playerName = CGI->generaltexth->translate("core.genrltxt.434");
localPlayerNames.push_back(playerName);
}
gameChat->resetMatchState();
lobbyClient->resetMatchState();