fixed crash on joining a server
This commit is contained in:
@@ -57,14 +57,10 @@ namespace OpenRA
|
||||
}
|
||||
|
||||
public void SetLocalPlayer(int index)
|
||||
{
|
||||
if (index != localPlayerIndex)
|
||||
{
|
||||
localPlayerIndex = index;
|
||||
Game.viewport.GoToStartLocation(LocalPlayer);
|
||||
//Game.chat.AddLine(LocalPlayer, "is now YOU");
|
||||
}
|
||||
if (!string.IsNullOrEmpty(Game.Settings.PlayerName) && LocalPlayer.PlayerName != Game.Settings.PlayerName)
|
||||
if (!string.IsNullOrEmpty(Game.Settings.PlayerName)
|
||||
&& Game.LobbyInfo.Clients[index].Name != Game.Settings.PlayerName)
|
||||
Game.IssueOrder(Order.Chat("/name " + Game.Settings.PlayerName));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user