Skip to main content

Shoot Projectile

The arc:on_shoot_projectile action type is triggered when a player shoots a projectile, such as an arrow or a snowball.

Action Data

When this action is triggered, the following action data is made available to be used by conditions and rewards:

Action Data TypeDescription
arc:item_stackRepresents a stack of items, including item type and quantity.
arc:entityRepresents an entity in the game, such as a player, mob, or item.

Example

The following example will set any arrow shot by the player on fire for 2000 ticks (100 seconds).

data/my_datapack/arc/set_arrow_on_fire.json
{
"holder": {
"type": "arc:player",
"id": "arc:player"
},
"type": "arc:on_shoot_projectile",
"conditions": [
{
"type": "arc:entity_type",
"entity_type": "minecraft:arrow"
}
],
"rewards": [
{
"type": "arc:entity_on_fire",
"ticks": 2000
}
]
}

Compatible Condition Types

The following condition types can be used with this action type:

Compatible Reward Types

The following reward types can be used with this action type: