Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions TShockAPI/GetDataHandlers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3386,6 +3386,16 @@ private static bool HandleProjectileNew(GetDataHandlerArgs args)
}

private static bool HandleNpcStrike(GetDataHandlerArgs args)
{
if (!HandleNpcStrikeInner(args))
return false;

// If we don't ack the damage on a rejected packet, the NPC will appear to deplete its health only for that client.
args.Player.SendData(PacketTypes.DamageNPCAck);
return true;
Comment thread
ZakFahey marked this conversation as resolved.
}

private static bool HandleNpcStrikeInner(GetDataHandlerArgs args)
{
short id = args.Data.ReadInt8();
var generation = args.Data.ReadInt8();
Expand Down
Loading