Slimefun

Slimefun

3M Downloads

Enabling `call-explosion-event` will not drop Slimefun blocks when breaking it using explosive tools.

variananora opened this issue · 4 comments

commented

❗ Checklist

  • I am using the official english version of Slimefun and did not modify the jar.
  • I am using an up to date "DEV" (not "RC") version of Slimefun.
  • I am aware that issues related to Slimefun addons need to be reported on their bug trackers and not here.
  • I searched for similar open issues and could not find an existing bug report on this.

📍 Description

Enabling call-explosive-event on explosive tools caused only the targeted Slimefun blocks to be dropped and drop nothing on the exploded part. This only happens to Slimefun blocks, vanilla blocks will drop just fine. Also this seems to clear block storage data on that coordinate as well.

📑 Reproduction Steps

  1. Enable call-explosive-event on explosive pickaxe
  2. Try to break Slimefun blocks
  3. See it only drops the one you are hitting with it

💡 Expected Behavior

It should drop all the Slimefun blocks

📷 Screenshots / Videos

https://youtu.be/OG7TwUCqqzg

📜 Server Log

No response

📂 /error-reports/ folder

No response

💻 Server Software

Paper

🎮 Minecraft Version

1.19.x

⭐ Slimefun version

This Server uses the following setup of Slimefun:
Paper git-Paper-42 (MC: 1.19)
Slimefun DEV - 1015 (git 2c4f886f)
Metrics-Module #28
Java 17

Installed Addons: (2)
  CMILib v1.2.1.0
  CMI v9.2.0.3

🧭 Other plugins

Plugins (7): CMI, CMILib, Multiverse-Core, Slimefun, Vault, VoidGen, WorldEdit
commented

I spent most of my time debugging this, the returned list from the blockExplodeEvent inside the ExplosiveTool.class are mutated and something is messing with it in the internals, its not giving the expected list given from the constructor of the block explode event and is being mutated after the event is called and doing a call to #blockList() returns only air blocks while the solid blocks are being filtered for a reason I can't really tell why.

commented

image
an image of the original block list that are intentionally filtered (should also contain air blocks if unfiltered) for debugging versus the block explode event block list which only returns air blocks even though the original block list with the solid blocks destroyed are passed in the constructor of the event

commented

Players from my server reported explosive pickaxe is breaking only 1 block and not 3x3
Letme know - if there is something i can do to help.
I not use slimefun addons, only master:
Slimefun4 - DEV 1047 (git 84008)

commented

I'm pretty sure I found the culprit: line 52 of ExplosionsListener.java
If you follow the methodcalls it takes you to line 88 and 89 where the blockstorage is cleared (as mentioned in the issue description) and the material is set to AIR (which would explain the debug commented previously)
This is also the only BlockExplodeEvent eventhandler Github could find, which further proves my suspicions