PaperMC / PaperMC/Paper

Guard more event calls in hot code

Open
#14,153 2 comments 1 reaction 1 assignee View on GitHub

@kennytv is already working on this.

Since Aug 7, 2026.

for: future scope: performance
Dominant language
Java
Stars
12.7k
Forks
3.5k
Avg merge
3d 13h
Merged PRs (30d)
11

Description

Events like the entity move and collide events check the handler list listener count before being called; do this to more events in hot code, ideally with a less verbose way. In some cases (where reasonable without additional diff) it can also be better to avoid data wrapping/coping that comes with event calls.

(assigned myself for an initial lookover, but this isn't limited to just me)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.