PaperMC / Paper

The most widely used, high performance Minecraft server that aims to fix gameplay and mechanics inconsistencies
https://papermc.io/
Other
9.98k stars 2.32k forks source link

EntityKnockbackEvent not firing for other TNT when a TNT explodes #10452

Open JeroenoBoy opened 6 months ago

JeroenoBoy commented 6 months ago

Expected behavior

I expect the EntityKnockbackEvent to also fire when a primed TNT pushes another primed TNT Additionally, it would also be nice if there was an EntityExplodedEvent#getEntityList()

Observed/Actual behavior

The event does not fire when event.getHitBy() and event.getEntity() are both TNTPrimed

Steps/models to reproduce

Build a simple cannon like so: image

Add the following EventListener:

public class TestListener implements Listener {
    public void onEntityKnockback(EntityKnockbackByEntityEvent event) {
        Bukkit.broadcastMessage("HitBy: " + event.getHitBy().getType() + " Entity: " + event.getEntity().getType());
    }
}

Shoot the cannon

Plugin and Datapack List

FAWE, kotlin-stdlib, LuckPerms, PlaceholderAPI, PlugManX, spark, CustomPlugin

Paper version

[14:46:40 INFO]: This server is running Paper version git-Paper-493 (MC: 1.20.4) (Implementing API version 1.20.4-R0.1-SNAPSHOT) (Git: a6b6ecd) You are running the latest version Previous version: git-Paper-485 (MC: 1.20.4)

Other

No response

electronicboy commented 6 months ago

public void onEntityKnockback(EntityKnockbackByEntityEvent event) {

which import is that?

electronicboy commented 6 months ago

nvm, that's the paper one, can tell with the method call on it

JeroenoBoy commented 4 months ago

Is there any ETA for when this will be fixed, would be much appreciated 😁