Skip to main content

Projectile Owner (Bi-Entity Condition Type)

Checks whether the target is a projectile (an arrow, trident, snowball, fireball, potion or any other projectile) and the actor is the entity that owns it, usually whoever shot or threw it.

Type ID: apoli:projectile_owner

Anything that isn't a projectile fails, even when the actor owns it, so a tamed wolf doesn't pass, and neither does an arrow someone else fired. apoli:owner is the wider check that also covers tamed animals.

Fields

This condition has no fields.

Examples

{
    "type": "apoli:action_on_hit",
    "self_action": {
        "type": "apoli:area_of_effect",
        "radius": 8,
        "bientity_condition": {
            "type": "apoli:projectile_owner"
        },
        "bientity_action": {
            "type": "apoli:target_action",
            "action": {
                "type": "apoli:execute_command",
                "command": "kill @s"
            }
        }
    }
}

Every melee hit clears away the holder's own arrows and thrown projectiles within 8 blocks, and leaves everybody else's alone.