Update editor sidebar when a player is removed.

This commit is contained in:
Noam
2018-10-04 00:12:33 +03:00
committed by abcdefg30
parent 52900f8112
commit c71f97e2c6
2 changed files with 21 additions and 9 deletions

View File

@@ -172,7 +172,10 @@ namespace OpenRA.Mods.Common.Traits
var index = int.Parse(name.Substring(5));
if (index >= newCount)
{
Players.Players.Remove(name);
OnPlayerRemoved();
}
}
for (var index = 0; index < newCount; index++)
@@ -249,6 +252,8 @@ namespace OpenRA.Mods.Common.Traits
return screenMap.At(worldPx);
}
public Action OnPlayerRemoved = () => { };
string NextActorName()
{
var id = previews.Count();