From ad28771e2c240ac5b1a52eea907b17813e9cb7fa Mon Sep 17 00:00:00 2001 From: Chris <2648373+QuiCM@users.noreply.github.com> Date: Sat, 30 Mar 2019 16:31:20 +1030 Subject: [PATCH] Update players when they die to hopefully stop their items floating at their grave --- TShockAPI/GetDataHandlers.cs | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/TShockAPI/GetDataHandlers.cs b/TShockAPI/GetDataHandlers.cs index 2d024bb1..99264206 100644 --- a/TShockAPI/GetDataHandlers.cs +++ b/TShockAPI/GetDataHandlers.cs @@ -2860,14 +2860,6 @@ namespace TShockAPI var type = Main.projectile[index].type; - // Players can no longer destroy projectiles that are not theirs as of 1.1.2 - /*if (args.Player.Index != Main.projectile[index].owner && type != 102 && type != 100 && !TShock.Config.IgnoreProjKill) // workaround for skeletron prime projectiles - { - args.Player.Disable(String.Format("Owner ({0}) and player ID ({1}) does not match to kill projectile of type: {3}", Main.projectile[index].owner, args.Player.Index, type)); - args.Player.RemoveProjectile(ident, owner); - return true; - }*/ - if (TShock.CheckIgnores(args.Player)) { args.Player.RemoveProjectile(ident, owner); @@ -2955,6 +2947,8 @@ namespace TShockAPI } } + //Attempt to resolve issue where player's slected items sometime fail to stop rendering when they die (eg chainsaws) + NetMessage.SendData((int)PacketTypes.PlayerUpdate, -1, args.Player.Index, NetworkText.Empty, args.Player.Index); return false; }