From 92165cebc2eba47185f0d3ba4bcbfc7dc066be4e Mon Sep 17 00:00:00 2001 From: teascade Date: Fri, 7 Aug 2020 22:40:37 +0300 Subject: [PATCH] Skip uninitialized players on MultiplePlayerUpdate --- Assets/Scripts/Networking/Packets/PlayerUpdatePckt.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Assets/Scripts/Networking/Packets/PlayerUpdatePckt.cs b/Assets/Scripts/Networking/Packets/PlayerUpdatePckt.cs index 352dbc0..b7696df 100644 --- a/Assets/Scripts/Networking/Packets/PlayerUpdatePckt.cs +++ b/Assets/Scripts/Networking/Packets/PlayerUpdatePckt.cs @@ -13,6 +13,9 @@ namespace NeonTea.Quakeball.Networking.Packets { public MultiplePlayerUpdatesPckt(List players) { foreach (NetPlayer p in players) { + if (p.Controlled == null) { + continue; + } Updates.Add(p.Controlled.CreatePacket(p.Id)); } }