Skip to main content

Spawners

The Spawners module provides an easy way of spawning items, splash potions, and living entities into the world, without using actual spawner blocks with NBT editors.

The module uses the same syntax as Kits to define items and makes use of a specific region to spawn them in.

ElementDescription
<spawners> </spawners>Node containing all defined spawners used in this map.
Sub-elementsValue/Children
<spawner> </spawner>An individual spawner.Spawner Sub-elements

Spawner Attributes

AttributeDescriptionValueDefault
spawn-regionRequiredThe region in which to spawn the target entities.Region
player-regionRequiredThe region used to determine whether the spawner is actively spawning entities. At least 1 player must be in this region for the spawner to be active.Region
max-entitiesA limit of how many entities this spawner can have spawned at once.Numberoo (infinity)
delayInterval in between spawning attempts.Time Period10s
min-delayUsed to randomize the spawn interval. Combine this with max-delay to create random intervals in between two values.
Cannot be combined with delay.
Time Perioddelay
max-delayUsed to randomize the spawn interval. Combine this with min-delay to create random intervals in between two values.
Cannot be combined with delay.
Time Perioddelay
filterFilter to further control spawn conditions, will return true if at least one player in player-region meets criteria.Filter

Spawner Sub-elements

ElementDescriptionValue
<item> </item>An item that will be dropped in the spawn-region.Item
<potion> </potion>A single splash potion that will be dropped in the spawn-region.Potion Effects
<mob />A living entity that will be spawned in the spawn-region.
Note: Wither and Ender Dragon cannot be spawned.
Creature Type

Examples

Item Spawner

This will spawn golden swords (in stacks of 1) in the red base, provided there is at least 1 person in that base. The swords will spawn in ramdom intervals of 2s - 10s. The insures that only players on the red team can trigger the spawner.

<spawners>
<spawner spawn-region="red-base" player-region="red-base" max-entities="50" min-delay="2s" max-delay="10s" filter="only-red">
<item amount="1" name="`6Golden Sword" material="gold sword"/>
</spawner>
</spawners>

Splash Potion Spawner

This will spawn a single splash potion that gives players Absorption III, Speed II and Jump Boost II. The speed and jump boost effects will both last 10 seconds and aborbtion will last 60 seconds. The damage attribute will give the potion a red appeareance based on Potion Values.

<spawners>
<spawner spawn-region="spawner" player-region="spawner-area" delay="2s">
<potion duration="10" amplifier="2" damage="5">
<effect amplifier="3" duration="60">absorption</effect>
<effect>speed</effect>
<effect>jump_boost</effect>
</potion>
</spawner>
</spawners>

Mob Spawner

This will spawn baby zombies named "Boss" with 20 hearts and are on fire for 30 seconds.

<spawners>
<spawner spawn-region="south-mob-point" player-region="south-mob" delay="4s">
<mob type="Zombie" custom-name="Boss" custom-name-visible="true" baby="true"
health="40" max-health="40" fire-ticks="600" can-pickup-items="false"/>
</spawner>
</spawners>

This will spawn bees that are silent, glowing, invulnerable, and have AI. They will also be permanently angry, have nectar, and be unable to enter hives.

<spawners>
<spawner spawn-region="north-mob-point" player-region="north-mob" delay="4s">
<mob type="Bee" silent="true" glowing="true" invulnerable="true" ai="true"
anger="100" has-nectar="true" cannot-enter-hive-ticks="600"/>
</spawner>
</spawners>

You can also spawn multiple mobs with predefined kits, even with minor changes on a per-mob basis. This example will spawn a normal skeleton and a wither skeleton with a kit called "boss-skeleton".

<kits>
<kit id="boss-skeleton">
<helmet material="iron helmet" drop-chance="0"/>
<chestplate material="iron chestplate" drop-chance="0"/>
<item slot="weapon.mainhand" material="iron sword" unbreakable="true" drop-chance="0.7"/>
<effect duration="255">strength</effect>
<attribute operation="add" amount="10">generic.max_health</attribute>
</kit>
</kits>

<spawners>
<!-- This mob will use the "boss-skeleton" kit defined above -->
<spawner spawn-region="west-mob-point" player-region="west-mob" delay="4s">
<mob type="Skeleton" custom-name="Captain" kit="boss-skeleton"/>
</spawner>
<!-- This mob will use the "boss-skeleton" kit defined above, but will also have its own kit -->
<spawner spawn-region="center-mob-point" player-region="center-mob" delay="4s">
<mob type="WitherSkeleton" custom-name="King" kit="boss-skeleton">
<kit>
<effect amplifier="2">speed</effect>
<attribute operation="add" amount="5">generic.attack_damage</attribute>
</kit>
</mob>
</spawner>
<!-- This mob will use its own kit -->
<spawner spawn-region="east-mob-point" player-region="east-mob" delay="4s">
<mob type="Spider" custom-name="Swift">
<kit attribute="generic.movement_speed:multiply:1.5;generic.attack_damage:add:3"/>
</mob>
</spawner>
</spawners>