Skip to main content

Get 25% OFF on your first order with BisectHosting using code "DAQEM"!

Spawn Entity

The arc:spawn_entity reward type spawns a specified entity near the player.

Parameters

ParameterTypeRequiredDefaultDescription
entity_typeEntityTypeRequired-No default valueType of entity to spawn.
countintOptional1Number of entities.

Example

The following example spawns a zombie when a player breaks a grave stone (custom block example).

data/my_datapack/arc/zombie_trap.json
{
"holder": {
"type": "arc:player",
"id": "arc:player"
},
"type": "arc:on_break_block",
"conditions": [
{
"type": "arc:block",
"block": "minecraft:stone"
}
],
"rewards": [
{
"type": "arc:spawn_entity",
"entity_type": "minecraft:zombie",
"count": 1
}
]
}

Compatible Action Types