Don't fire TNTPrimeEvent for EnderDragon + fixes#8075
Closed
Owen1212055 wants to merge 3 commits into
Closed
Conversation
Member
well we need to get rid of this then right? |
Member
Author
It's plugin set behavior by setting the yield to anything but 0 in the EntityExplodeEvent, sorry that wasn't clarified. |
Machine-Maker
approved these changes
Jun 29, 2022
Member
Author
|
Updated with another patch that shows the level effect + don't explode tnt. |
kennytv
reviewed
Jun 30, 2022
3a54f20 to
d2d3d30
Compare
Member
Author
|
Diff on change + rebased |
electronicboy
approved these changes
Sep 9, 2023
Warriorrrr
approved these changes
Sep 9, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This seems to have been back when the patch was originally made, but it doesn't make much sense for this to be here.
This caused every single block broken by the dragon to fire a TNTPrimeEvent (even if it wasn't TNT) IF EntityExplodeEvent yield was set to anything but 0.
Additionally, blocks that actually were TNT would fire another event because wasExploded calls the event.
This does cause a small behavior change in that this event will no longer cause the block to be removed.
However, because this event uses an EntityExplodeEvent you can still customize these blocks.
The behavior of tnt exploding/blocks dropping from ender dragons is not vanilla behavior.