RandomSpawns, built here as an effect type: a rule is an effect triggered by the world looking right.
Rules live in Effects/, and say so with type: spawn:
type: out and an entry is the named effect it always was, so nothing you already wrote changes.
Fields
Keys are case-insensitive and
- and _ are interchangeable.
Caps
max-nearby and max-per-chunk are counted off the mobs actually standing there, so they hold exactly, restarts included. max-per-world and max-per-player are counted from what the server has loaded, so they cannot see mobs in chunks nobody has visited this session — treat those two as a brake on runaway spawning rather than exact accounting.
Server-wide defaults
Any cap a rule does not name falls back toconfig.yml, so you can tune density for a pack of rules somebody else wrote without editing their files:
0 means no ceiling.
Conditions
cond: is the ordinary effect condition language, so everything that works in an if{} line works here — including any condition an addon registered.
isBiome, isBlock, light, y, moonphase and the rest — is listed under Place conditions.
A rule’s conditions are evaluated about a place, before anything is spawned, so there is no caster. A condition that reaches for one simply never passes here.
cond: cannot be parsed loads disabled rather than being skipped, for the same reason a spawner’s does: a gate that quietly disappears is worse than no rule at all.
How the scan works
The scan is anchored to players, not to the world: for each player online it tries a handful of candidate points in a shell around them, walking down from near their Y so caves and surface both get looked at. That means the cost scales with how many people are online, not with world size — an empty server does nothing at all. Chunks are never force-loaded.attempts-per-player is the whole cost of the system: raise it for denser spawning, lower it on a busy server. Each rule’s own rate and caps still apply on top.
Replacing vanilla spawns
replaces: hooks natural vanilla spawning: whenever the server would have spawned one of those, your mob appears instead. suppress-original: true means the vanilla mob never appears even when your rule declines.
A rule with
replaces: is driven by vanilla spawning alone and is skipped by the player scan. The two are alternatives, not additions — a rule doing both would spawn twice over from two unrelated clocks. If you want both, that is a rule each.Driving them
/nme spawnrule — list, info, test, trigger, enable, disable, reset. test tells you, where you are standing, whether each rule would spawn and why not.
From code, including shipping rules from a world-generator plugin: Natural Spawns in the API section.
