More security checks

This actually looks pretty bad, not gonna lie.
This commit is contained in:
juanjp600
2016-08-28 19:54:31 -03:00
parent b51afdd0cb
commit 73fc0cf724
4 changed files with 23 additions and 6 deletions
+1 -1
View File
@@ -1702,7 +1702,7 @@ namespace Barotrauma
{
data = null;
if (GameMain.Server != null && type != NetworkEventType.InventoryUpdate)
if (GameMain.Server != null && (type != NetworkEventType.InventoryUpdate || (!IsUnconscious && !IsDead)))
{
Client sender = GameMain.Server.ConnectedClients.Find(c => c.Connection == message.SenderConnection);
if (sender == null || sender.Character != this)