Fixed characters not appearing in the round summary in mp, minor CrewManager refactoring

This commit is contained in:
Joonas Rikkonen
2017-11-20 20:21:18 +02:00
parent 765587efd7
commit fce7d43ef3
13 changed files with 89 additions and 57 deletions
@@ -192,9 +192,9 @@ namespace Barotrauma
if (controlled == this) controlled = null;
if (GameMain.GameSession?.CrewManager != null &&
GameMain.GameSession.CrewManager.characters.Contains(this))
GameMain.GameSession.CrewManager.GetCharacters().Contains(this))
{
GameMain.GameSession.CrewManager.characters.Remove(this);
GameMain.GameSession.CrewManager.RemoveCharacter(this);
}
if (GameMain.Client != null && GameMain.Client.Character == this) GameMain.Client.Character = null;