Replies: 1 comment
-
I'm not sure what this means. Anytime what changes on a block entity, anything that is stored in NBT? that means every single tick, it would fire for every furnace because the burn/fuel time is stored in NBT. Anything any inventory changed, including anything hopper-related. We already have intense events for those in the InventoryMoveItemEvent.
While this might be true, it's not generally good practice to have 2 events for one thing. That can cause more confusion around which event is fired first, what happens if I cancel the first one, does the second one fire, etc. There is a pretty good catch-all that happens when a block changes in any way, the I'll wait to see what others say about this, but for now, I'm in the camp of "close this, as its too invasive/complex and redundant given all the other events that we have". |
Beta Was this translation helpful? Give feedback.
-
Is your feature request related to a problem?
Right now, if you want to restrict block modifications, you need a heavy plugin like CoreProtect, etc. I would like to make a plugin that detects when a block is replaced, and stop it.
Describe the solution you'd like.
A new class called BlockModifyEvent, the event would contain a property for the block, the old state, and the new state, and a cause enum, which can be one of the following:
Describe alternatives you've considered.
Handling every single possible event for blocks changing is extremely hard to maintain.
Other
No response
Beta Was this translation helpful? Give feedback.
All reactions