Repository navigation
Spawner modifiers
Spawner modifiers are special items that players can apply to a spawner to change how it behaves.
Examples include reducing the health of spawned mobs, applying potion effects, or adjusting the value of a spawner upgrade. Each modifier is configured in the modifiers.yml file.
Modifiers can be applied to a spawner in the upgrade GUI by clicking on the modifier in the bottom inventory. Modifiers can be removed by clicking on the modifier item in the upgrade GUI.
A modifier stays active on the spawner until it runs out of usages (if a usage limit is set), or until the player removes it.
Every modifier is defined under the Modifiers section and is identified by a
unique key.
The file contains one example modifier – generic. To add a new modifier, copy the entire
generic block and paste it below, then change generic to your chosen key and adjust the values.
Modifiers:
generic: # the modifier key
display: ...
item: ...
requirements: ...
effect: ...
new_modifier: # your new modifier
display: ...
...display: "<red-#ffbf00>Health reduction"A name shown to players when they apply or remove the modifier.
Defines the modifier item that will be given to players.
item:
material: PAPER
name: "<#red-#ffbf00>Health reduction modifier <#bfffff>(-%value%%)"
lore:
- ""
- "<#8fbfbf><!italic>Reduces mob health by %value% percent"
- " <#8fbfbf><!italic>upon spawning."
model: 0
glint: true-
material- item material type. -
name- display name, supports placeholders (see Parameters and placeholders). -
lore- item description, supports placeholders. -
model- custom model data value, set to0to disable. -
glint- whether the item has enchantment glint
Requirements control which spawners a modifier can be applied to.
requirements:
spawner-level:
level: 0
ignore: []
spawner-types:
list: []
exclude: false-
spawner-level:-
level- minimum spawner level required before this modifier can be applied; a spawner's level equals the total number of upgrade levels across all of its upgrades, except ignored ones (e.g. a spawner with no upgrades is level0; one level-up in each of the 6 upgrade types makes it level6). You can use *%required_level%placeholder in the item name or lore to display this number. - ignore - list of upgrade types that will not count towards the required level (e.g.
[DELAY, NEARBY]); Leave empty ([]) to allow all upgrade types.
-
-
spawner-types:-
list- list of spawner types this modifier can be applied to (e.g.[ZOMBIE, SKELETON]); Leave empty ([]) to allow all spawner types. -
exclude- whentruethelistbecomes a blacklist.
-
The effect section defines what the modifier does. The required fields vary by effects — see built-in effects below.
effect:
id: change-attribute
attribute: health
evaluate-type: SUBTRACT_PERCENTParameters required when giving a modifier item for all effects:
-
usage- how many times this modifier activates before it stops working; use#infinitefor unlimited activations. -
chance- chance (1–100) that the modifier activates each time a mob spawns; use100for it to always activate.
Modifies a specific attribute of spawner summoned mobs.
effect:
type: change-attribute
attribute: <attribute>
evaluate-type: <evaluate type>See attributes and evaluate types.
Parameters required when giving a modifier item:
-
value- amount to apply (must be greater than0).
Modifies the value of one of the spawner's upgrades — for example, increasing the spawn range or decreasing the spawn delay.
effect:
id: change-upgrade
evaluate-type: <evaluate type>
upgrade-type: <upgrade type>See evaluate types and upgrade types.
Parameters required when giving a modifier item:
-
value- amount to apply to the upgrade value (must be greater than0).
Applies a potion effect to spawner summoned mobs.
effect:
id: apply-effect
potion-type: <potion type>See potion types.
Parameters required when giving a modifier item:
-
duration- how long the potion effect lasts, in ticks (20 ticks = 1 second); use#infinitefor an infinite duration; must be greater than0. -
amplifier- strength level of the effect (e.g.1= level I,2= level II); must be greater than0. -
ambient- should the effect be ambient (more and slightly translucent). -
particles- should the effect produce particles.
Disables the ai of spawner summoned mobs (unable to move or attack, but can be pushed).
effect:
id: disable-aiNo additional parameters required
Set spawner summoned mobs on fire.
effect:
id: set-fireParameters required when giving a modifier item:
-
ticks- how long the fire will last, in ticks (20 ticks = 1 second)
Sets spawner summoned mobs silent.
effect:
id: set-silentNo additional parameters required
Sets spawner summoned mobs have a glowing effect.
effect:
id: set-glowingNo additional parameters required
When a modifier item is given to a player via a command, the command includes parameter values
(e.g. the value reduction amount or number of usages). These values can be displayed in the item's
name and lore using placeholders.
| Placeholder | Description |
|---|---|
%usage% |
number of activations remaining. Displays ∞ when set to infinite |
%chance% |
activation chance percentage |
%value% |
effect value (e.g. percentage or flat amount) |
%duration% |
potion effect duration in seconds. Displays ∞ when set to infinite |
%amplifier% |
potion effect level |
%ambient% |
true or false
|
%particles% |
true or false
|
%required_level% |
minimum spawner level required to apply this modifier |
Note! That some placeholders will display regular numbers, but for some you might want to display Roman numerals, that can be done by adding :r after the placeholder (e.g. %amplifier:r%), and for values that use ticks you might want to display seconds, that can be my adding :sn after the placeholder (e.g. %duration:s0%) where n is the decimal points.
Below is a complete modifiers.yml with two modifiers: one that reduces mob health and one that
applies a poison effect.
Modifiers:
health_reduction:
display: "<red>Health reduction"
effect:
id: change-attribute
attribute: health
evaluate-type: SUBTRACT_PERCENT
item:
material: PAPER
name: "<red>Health reduction <gray>(-%value%%)"
lore:
- ""
- "<gray>Reduces mob health by %value%%"
- "<gray>Usages: %usage%"
- "<gray>Chance: %chance%%"
model: 0
glint: true
poison_spawner:
display: "<green>Poison spawner"
effect:
id: apply-effect
potion-type: poison
requirements:
spawner-level:
level: 3
spawner-types:
list: [ZOMBIE, SKELETON, CREEPER]
item:
material: FERMENTED_SPIDER_EYE
name: "<green>Poison modifier <gray>(Poison %amplifier:r%)"
lore:
- ""
# have to use %duration:s0% with the ':s0' to convert ticks into seconds, with no decimal point
- "<gray>Applies Poison %amplifier:r% for %duration:s0%s"
- "<gray>to each spawned mob."
- "<gray>Usages: %usage%"
- "<gray>Chance: %chance%%"
- ""
- "<yellow>Requires spawner level %required_level%"
- "<yellow>Only applies to Zombies, Skeletons and Creepers"
model: 0
glint: true