Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete unnecessary Listeners to optimize #210

Closed
KioProject123 opened this issue Apr 11, 2022 · 1 comment · Fixed by #211
Closed

Delete unnecessary Listeners to optimize #210

KioProject123 opened this issue Apr 11, 2022 · 1 comment · Fixed by #211
Assignees
Labels
enhancement New feature or request

Comments

@KioProject123
Copy link

KioProject123 commented Apr 11, 2022

Description

BlockPhysicsEvent is a heavy event, and the falling blocks will trigger EntityChangeBlockEvent too
EntityInteractEvent is a heavy event, and entity destroy blocks will trigger EntityChangeBlockEvent too
(Entity stepping on red stone ore will trigger a large number of EntityInteractEvent)

So there is no need for BlockPhysicsEvent and EntityInteractEvent to exist.

Proposed Behaviour

.

Extra Details

No response

@KioProject123 KioProject123 added the enhancement New feature or request label Apr 11, 2022
@KioProject123 KioProject123 changed the title Delete BlockPhysicsEvent to optimize Delete unnecessary Listeners to optimize Apr 11, 2022
@Ingrim4
Copy link
Member

Ingrim4 commented Apr 13, 2022

Thanks for the recommendation. We first added the BlockPhysicsEvent due to issue #202 which it turns out wasn't our fault but a bug in spigot SPIGOT-6962. Regarding the EntityInteractEvent we will remove it (as well as the BlockPhysicsEvent) since all usefull calls of the event get covered by the EntityChangeBlockEvent.

@Ingrim4 Ingrim4 self-assigned this Apr 13, 2022
@Ingrim4 Ingrim4 mentioned this issue Apr 13, 2022
3 tasks
Ingrim4 added a commit that referenced this issue Apr 13, 2022
* Revert "[#202] deobfuscate block on block fall event (#203)"

This reverts commit 6278060.

* chore: remove EntityInteractEvent in favor of EntityChangeBlockEvent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants