Performance / Entity limitsPrivate source

EntityLimiter

Bounded entity populations without a blanket kill switch.

Per-type and per-group entity caps with radius or grid counting, per-world overrides and optional claim-provider hooks.

Status

Current build 2.3.6. The source is private and the README explicitly says a full version matrix has not been run.

Checked version 2.3.6

Evidence checked 2026-10-30

EntityLimiter case study visual

The problem

Entity farms, stacked mobs and item spills can turn a healthy chunk into a tick-time problem. A single global cap is easy to write and hard to operate: it either removes the wrong entities or leaves the actual offender untouched.

What I built

  • Built separate per-type and per-group limit families that are evaluated together.
  • Added RADIUS and GRID counting modes, per-world overrides and exempt worlds.
  • Kept Folia support reflective so the same jar still loads on Bukkit-family servers without Folia classes.
  • Added item provenance and claim-provider hooks instead of assuming every entity belongs to the server.

Architecture and trade-offs

Two limits, one decision

A type can be under its own cap while its group is already over budget. The plugin checks both, so a zombie limit and a monster-group limit can coexist without one silently disabling the other.

Bounded reconciliation

Entity validation is queued and capped per tick. The limiter does not scan every loaded chunk on every pass; it spreads work so cleanup does not become the new lag source.

Reflective platform support

Folia scheduler classes are resolved at runtime and cached. Bukkit paths remain free of hard Folia imports, which is what keeps a single artifact loadable across server families.

← All work