Add support for custom explosive blocks (as entities)
GuilleX7 opened this issue ยท 0 comments
Using servers like Mohist, ExplodeAny can be combined with Forge mods like https://www.curseforge.com/minecraft/mc-mods/homyatos-explosives, which add explosive blocks. Since these blocks operate using the Vanilla Minecraft API, they emit a BlockExplodeEvent when they explode. However, the originating block seems to be air, as happens with exploding Vanilla blocks.
While there exist some workarounds for tracking Vanilla blocks (such as listening to PlayerEnterBedEvent or PlayerInteractEvent and knowing the logic behind explosions), there's no way to know when these blocks will explode. It seems the only way is to track them after they've been placed (through BlockPlacedEvent and BlockBreakEvent), and then checking their positions when a BlockExplodeEvent has occurred.