Skip to main content

Entity In Block

The arc:entity_in_block condition type checks if an entity is currently inside a specific block.

Parameters

ParameterTypeRequiredDefaultDescription
blockBlockRequired-The block to check.

Example

The following example will pull the player towards their fishing hook only if the hook is in the air, effectively creating a grappling hook.

data/my_datapack/arc/grappling_hook.json
{
"holder": {
"type": "arc:player",
"id": "arc:player"
},
"type": "arc:on_rod_reel_in",
"conditions": [
{
"type": "arc:entity_in_block",
"block": "minecraft:air"
}
],
"rewards": [
{
"type": "arc:move_to_entity",
"force": 2.0
}
]
}

Compatible Action Types