Skip to content

Commit

Permalink
Apply deltamovement on explosion
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexProgrammerDE committed Nov 22, 2024
1 parent a4a22c1 commit 3ad27d8
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1043,6 +1043,13 @@ public void onEntityPositionSync(ClientboundEntityPositionSyncPacket packet) {
}
}

@EventHandler
public void onExplosion(ClientboundExplodePacket packet) {
if (packet.getPlayerKnockback() != null) {
localPlayer.addDeltaMovement(packet.getPlayerKnockback());
}
}

@EventHandler
public void onResourcePack(ClientboundResourcePackPushPacket packet) {
if (!isValidResourcePackUrl(packet.getUrl())) {
Expand Down

0 comments on commit 3ad27d8

Please sign in to comment.