This commit is contained in:
Matthias Mailänder
2014-01-26 07:54:52 +01:00
committed by Matthias Mailänder
parent e344b95a6f
commit 16ddecdcbf
2 changed files with 17 additions and 15 deletions

View File

@@ -88,7 +88,8 @@ namespace OpenRA
public OwnerInit() { } public OwnerInit() { }
public OwnerInit(string playerName) { this.PlayerName = playerName; } public OwnerInit(string playerName) { this.PlayerName = playerName; }
public OwnerInit( Player player ) { public OwnerInit(Player player)
{
this.player = player; this.player = player;
this.PlayerName = player.InternalName; this.PlayerName = player.InternalName;
} }
@@ -97,6 +98,7 @@ namespace OpenRA
{ {
if (player != null) if (player != null)
return player; return player;
return world.Players.First(x => x.InternalName == PlayerName); return world.Players.First(x => x.InternalName == PlayerName);
} }
} }