Fixed SetClientCharacter & Revive

This commit is contained in:
Joonas Rikkonen
2017-07-26 17:19:35 +03:00
parent f062ca0e4d
commit 6faf658ae0
3 changed files with 5 additions and 3 deletions
@@ -1868,13 +1868,12 @@ namespace Barotrauma.Networking
{
if (client.Character != null) //removing control of the current character
{
newCharacter.IsRemotePlayer = false;
CreateEntityEvent(client.Character, new object[] { NetEntityEvent.Type.Control, null });
client.Character = null;
}
}
else if (client.Character != newCharacter) //taking control of a new character
else //taking control of a new character
{
newCharacter.ResetNetState();
newCharacter.LastNetworkUpdateID = client.Character.LastNetworkUpdateID;