Creating Spawns
What are Custom Spawns?
Custom Spawns are used by Events and global reinforcements to set how, where and when an event should spawn the boss for that event.
Events and global reinforcements set which spawn they are using by writing down its filename.
Creating Custom Spawns
Custom Spawns go into the customspawns folder. One Custom Spawn can be used by several events at the same time, so you don't have to create one per event.
Here is an example Custom Spawn:
isEnabled: true
validWorldEnvironments:
- NORMAL
- CUSTOM
bypassWorldGuard: false
isSurfaceSpawn: true
Making an Anywhere Spawn
To make a spawn that can occur anywhere, your configuration should resemble the following:
isEnabled: true
canSpawnInLight: true
This configuration allows mobs to spawn in any location, in any world, at any time, and during any moon phase.
If you're interested in creating a more customized spawn, keep reading below.
Values
isEnabled
Sets if the spawn is enabled.
| Key | Values | Default |
|---|---|---|
isEnabled | Boolean | true |
Example
isEnabled: true
lowestYLevel
Sets the lowest y level (map height) used. Note that the default of 0 stops underground spawns from ever going below sea level - set this to a negative value such as -64 if you want spawns in deep caves.
| Key | Values | Default |
|---|---|---|
lowestYLevel | Integer | 0 |
Example
lowestYLevel: 0
highestYLevel
Sets the highest y level (map height) used.
| Key | Values | Default |
|---|---|---|
highestYLevel | Integer | 320 |
Example
highestYLevel: 320
validWorlds
Sets the list of the worlds where the custom spawn can happen. This setting can be left out to allow all your worlds to be valid.
| Key | Values | Default |
|---|---|---|
validWorlds | String List | none |
Example
validWorlds:
- WORLD
- FUN_LAND
If you want all your worlds to be valid you can just not use the setting or format it like this:
validWorlds: []
validWorldEnvironments
Sets the list of valid world environments where the custom spawn can happen. This setting can be left out to allow all environments to be valid.
| Key | Values | Default |
|---|---|---|
validWorldEnvironments | Environment List | none |
Example
validWorldEnvironments:
- NORMAL
- NETHER
If you want all environments to be valid you can just not use the setting or format it like this:
validWorldEnvironments: []
validBiomesV2
Intended to set the list of valid biomes where the custom spawn can happen.
This setting used to be called validBiomes in older versions of EM.
This setting currently does nothing. EliteMobs writes the key into your spawn file but never reads it back, so whatever you put in it is ignored and the spawn behaves as though no biome restriction were set.
Do not rely on it to keep a boss inside a specific biome. Use validWorlds or validWorldEnvironments instead, or restrict the spawn with isSurfaceSpawn / isUndergroundSpawn and the Y level settings.
| Key | Values | Default |
|---|---|---|
validBiomesV2 | Biome List | none |
earliestTime
Sets the earliest in-game time at which the custom spawn can happen. Unlike the other settings, earliestTime, latestTime and moonPhase are checked at the moment the boss is about to be placed rather than while the location is being searched for, so a spawn whose location was already found will simply wait until the time and moon conditions are met.
| Key | Values | Default |
|---|---|---|
earliestTime | Long | 0 |
Example
earliestTime: 0
latestTime
Sets the latest in-game time at which the custom spawn can happen.
| Key | Values | Default |
|---|---|---|
latestTime | Long | 24000 |
Example
latestTime: 24000
moonPhase
Sets the required moon phase for the custom spawn to occur.
| Key | Values | Default |
|---|---|---|
moonPhase | Special [1] | none |
Example
moonPhase: FULL_MOON
Special [1]
Expand Table
| Moon Phase | Preview |
|---|---|
NEW_MOON | 🌑 |
WAXING_CRESCENT | 🌒 |
FIRST_QUARTER | 🌓 |
WAXING_GIBBOUS | 🌔 |
FULL_MOON | 🌕 |
WANING_GIBBOUS | 🌖 |
WANING_CRESCENT | 🌘 |
LAST_QUARTER | 🌗 |
bypassWorldGuard
Intended to make the custom spawn bypass protection systems such as WorldGuard.
This setting currently does nothing. EliteMobs reads the key out of your spawn file but never acts on it, so WorldGuard flags are always checked regardless of what you set here. To let a spawn happen inside a protected region, set the relevant WorldGuard flags on that region instead.
| Key | Values | Default |
|---|---|---|
bypassWorldGuard | Boolean | false |
canSpawnInLight
Specifies whether the custom spawn can occur on blocks illuminated by light sources. When set to false, spawns only occur at light level 8 or below. When set to true, spawns can occur at any light level.
| Key | Values | Default |
|---|---|---|
canSpawnInLight | Boolean | false |
Example
canSpawnInLight: false
isSurfaceSpawn
Sets if the custom spawn can only happen at the surface of a world.
| Key | Values | Default |
|---|---|---|
isSurfaceSpawn | Boolean | false |
Example
isSurfaceSpawn: false
isUndergroundSpawn
Sets if the custom spawn can only happen underground.
| Key | Values | Default |
|---|---|---|
isUndergroundSpawn | Boolean | false |
Example
isUndergroundSpawn: false
How a spawn location is picked
EliteMobs does not scan the world for a spot. It picks a random online player and offsets from them:
- A player is chosen at random from the players that are eligible for this spawn. A player is skipped if their world is not in
ValidWorlds.yml, if they are inside an arena or dungeon instance, if mob spawning is turned off in their world, or if the spawn'svalidWorlds/validWorldEnvironmentsexclude their world. Timed events additionally skip players who are inside an EliteMobs dungeon world. - A candidate spot is picked between 24 and 128 blocks away from that player on both the X and Z axes, in any direction.
- The Y level is resolved according to
isSurfaceSpawn,isUndergroundSpawnor, if neither is set, by searching upwards for the first block with solid ground below it and two blocks of air above it. - The candidate is then run through the validations below.
Up to 100 candidates are tried, 4 per tick. If none of them work, EliteMobs waits a minute and tries again, so an event can take a while to actually appear on a busy or heavily protected server.
Spawn Validation Behavior
When EliteMobs attempts to spawn a boss using a Custom Spawn configuration, it performs several automatic validations beyond the configured fields:
- Player Proximity: Bosses will not spawn within 24 blocks of any player
- Nether Ceiling: Spawns above Y=127 are blocked in the Nether dimension
- Block Safety: Ensures spawns occur with solid ground and air space above
- Y Level: The final location must sit between
lowestYLevelandhighestYLevel - Game Rules: Respects the world's mob spawning game rule (
spawnMobson Minecraft 1.21.11 and newer,doMobSpawningbefore that) - WorldGuard Flags: Checks the
elitemobs-events,elitemob-spawningand WorldGuard's ownmob-spawningflags - Peace Banners: If
suppressEventsis enabled inPeaceBanner.yml(it is by default), areas protected by a peace banner are skipped - Final test spawn: Right before the boss appears, EliteMobs spawns and immediately removes a plain vanilla zombie at the location. If some other protection plugin blocks that zombie, the location is thrown out and the search restarts
These validations occur automatically and cannot be disabled through configuration.
