minecraft:projectile

Turns the entity into a projectile: a thrown or shot entity that flies along a ballistic arc and reacts when it impacts a block, a fluid, or another entity.

Properties

PropertyTypeDefaultWhat it does
offsetList of decimal or Object[0, 0, 0]Offset, relative to the `anchor`, at which the projectile is spawned when fired by the shooter.
xDecimal0
yDecimal0
zDecimal0
anchorTextorigin, eye_height, middle"origin"Reference point on the shooter used to position the projectile at spawn: `0` = origin (feet), `1` = eye height, `2` = middle of the bounding box.
powerDecimal1.3Initial speed (in blocks per tick) at which the projectile is launched.
angle_offsetDecimal0Additional upwards pitch (in degrees) applied to the shooter's aim direction at launch. Negative values aim downward.
uncertainty_baseDecimal0Base inaccuracy added to the launch direction. The total inaccuracy is `uncertainty_base - difficultyLevel * uncertainty_multiplier`.
uncertainty_multiplierDecimal0Per-difficulty-level reduction in inaccuracy. See `uncertainty_base` for the full formula.
shoot_targetBooleantrueIf `true`, the projectile is aimed at the shooter's current target (when one exists) rather than straight ahead.
gravityDecimal0.05Downward acceleration (blocks per tick squared) applied each tick while in flight. Higher values make the projectile fall faster.
inertiaDecimal0.99Fraction of the projectile's velocity preserved each tick while traveling through air. Values below `1.0` cause it to slow down over time.
liquid_inertiaDecimal0.6Fraction of the projectile's velocity preserved each tick while traveling through a fluid.
isolated_physicsBooleantrueIf `true`, the projectile uses a dedicated ballistic physics path and ignores generic actor movement systems (friction, drag, etc.). Recommended for custom projectiles.
homingBooleanfalseIf `true`, the projectile steers towards an active target while in flight.
should_bounceTextno, if_invulnerable, if_no_damage_dealt"no"Controls whether the projectile bounces off entities on impact. `no` disables bouncing, `if_invulnerable` bounces only off invulnerable entities, and `if_no_damage_dealt` bounces whenever no damage is dealt to the target.
multiple_targetsBooleanfalseIf `true`, the projectile can hit more than one entity over the course of its flight; if `false`, it stops at the first entity it hits. Projectiles launched with the Piercing enchantment have this value set to `true`.
hit_nearest_passengerBooleanfalseIf `true`, when the projectile hits a vehicle with at least one passenger, the on-hit behavior is applied to the passenger closest to the impact point instead of the vehicle itself.
ignored_entitiesList of text[]Array of entity identifiers that the projectile will pass through without registering a hit.
is_dangerousBooleanfalseIf `true`, the projectile is flagged as dangerous, affecting AI reactions and certain client-side behaviors.
reflect_on_hurtBooleanfalseIf `true`, the projectile reverses direction when struck, reflecting back towards the attacker.
reflect_immunityDecimal0Duration in seconds after launch during which the projectile cannot be reflected by being struck.
destroy_on_hurtBooleanfalseIf `true`, the projectile is removed from the world when struck.
stop_on_hurtBooleanfalseIf `true`, the projectile has its velocity zeroed out when struck.
crit_particle_on_hurtBooleanfalseIf `true`, critical-hit particles are spawned on the projectile when it is struck.
particleTextnone, bubble, bubblemanual, crit, blockforcefield, smoke, explode, evaporation, flame, candleflame, lava, largesmoke, reddust, risingborderdust, iconcrack, snowballpoof, largeexplode, hugeexplosion, breezewindexplosion, mobflame, heart, terrain, townaura, portal …"iconcrack"Particle effect emitted at the impact location when the projectile hits something.
shoot_soundText""Identifier of the sound to play when the projectile is fired.
hit_soundText""Identifier of the sound to play when the projectile hits an entity. Also used for block hits when `hit_ground_sound` is not specified.
hit_ground_soundText""Identifier of the sound to play when the projectile hits a block. Defaults to `hit_sound` when empty.
catch_fireBooleanfalseLegacy default for whether the projectile sets the entity hit on fire. Prefer the `catch_fire` on-hit subcomponent.
spread_fireBooleantrueIf `true`, when hitting an entity and the projectile is on fire, spread the fire to the entity.
on_fire_timeDecimal5Duration in seconds for which an entity set on fire by this projectile remains burning. Applied both by the legacy top-level `catch_fire` flag and by the `catch_fire` on-hit subcomponent.
lightningBooleanfalseIf `true`, the projectile can channel a lightning bolt when it hits an entity during a thunderstorm.
potion_effectInteger-1Default potion aux value associated with the projectile. Normally set programmatically by potion items; rarely useful at authoring time. A value matching the water potion is required for the `douse_fire` on-hit subcomponent to extinguish fires.
splash_rangeDecimal4Splash radius (in blocks) used when applying potion effects via the splash/lingering potion code path.
on_hitObject—Map of on-hit subcomponents that drive what happens when the projectile impacts a block, fluid, or entity. Each key is a subcomponent name and its value is that subcomponent's configuration.
arrow_effectObject—Variant of `mob_effect` that derives the effects from the arrow's tipped-potion data and splits durations across the standard eight-arrow stack.
apply_effect_to_blocking_targetsBooleantrueIf `true`, effects are still applied to targets that blocked the projectile.
catch_fireObject—Causes the projectile to embed itself in the block it hits.
on_fire_timeDecimal0Duration in seconds for which entity remains on fire
fire_affected_by_griefingBooleanfalseIf `true`, the block-ignition behavior is suppressed when the shooter is a mob and the `mobGriefing` game rule is off.
definition_eventObject—Fires an entity event on the shooter, the projectile, the entity hit, and/or all entities in a splash radius.
affect_shooterBooleanfalseIf `true`, the event is fired on the projectile's shooter.
affect_projectileBooleanfalseIf `true`, the event is fired on the projectile entity itself.
affect_targetBooleanfalseIf `true`, the event is fired on the entity hit by the projectile.
affect_splash_areaBooleanfalseIf `true`, the event is fired on every entity within `splash_area` blocks of the impact.
splash_areaDecimal0Radius (in blocks) used by `affect_splash_area`.
event_triggerObject{"event": "", "filters": {"AND": null, "NOT": null, "OR":…Event trigger (with optional filters) to fire on the selected target(s).
douse_fireObject—When the projectile is a water-effect potion, extinguishes fires and campfires at and around the hit block.
freeze_on_hitObject—Freezes nearby water blocks to ice in a configurable volume around the impact (Education Edition chemistry feature).
sizeDecimal1Half-extent of the freezing volume (in blocks).
snap_to_blockBooleanfalseIf `true`, the freezing volume is centered on the hit block's center instead of the precise impact point.
shapeTextcube, sphere"cube"Shape of the freezing volume. Allowed values: `cube`, `sphere`.
grant_xpObject—Drops experience orbs at the impact location.
minXPInteger0Minimum amount of experience to drop.
maxXPInteger0Maximum amount of experience to drop.
hurt_ownerObject—Damages the projectile's owner when the projectile lands.
owner_damageDecimal0Amount of damage to deal to the owner.
knockbackBooleanfalseIf `true`, the damage applies knockback to the owner.
igniteBooleanfalseIf `true`, the damage sets the owner on fire.
igniteObject—Triggers the entity's `on_ignite` definition when the projectile hits.
impact_damageObject—Deals damage to the entity that was hit and optionally applies knockback, fire, channeling, and critical-hit scaling.
damageObject{"max": 0, "min": 0}Range of damage to apply on impact. A random value in `[min, max]` is rolled per hit and the velocity-scaled `power_multiplier` term is added to it to define the projectile's base damage.
filterText""Entity family or type that the projectile is restricted to damaging. Entities outside the filter are not damaged.
knockbackBooleanfalseIf `true`, the entity hit is knocked back away from the projectile.
catch_fireBooleanfalseIf `true`, the entity hit is set on fire (uses the projectile's `on_fire_time`).
channelingBooleanfalseIf `true`, the projectile can call down a lightning bolt on the entity hit during a thunderstorm.
difficulty_randomizationTextnone, additive, multiplicative"none"Controls how world difficulty contributes to the rolled damage. `none` ignores difficulty, `additive` adds a difficulty-driven term on top of the base damage, and `multiplicative` folds the difficulty term into `power_multiplier` before scaling by velocity.
power_multiplierDecimal0Multiplied by the projectile's velocity and added to the rolled `damage` to define the projectile's base damage, so it can be used on its own to scale damage by the projectile's velocity.
ceil_pre_critical_damageBooleanfalseIf `true`, rounds the projectile's damage up to the next integer before the critical-hit multiplier is applied.
min_critical_damageInteger0If specified, sets the minimum damage after critical damage has been applied. Enchantments have already been applied at this point, so this clamps the final damage value of critical hits.
max_critical_damageInteger2147483647If specified, sets the maximum damage after critical damage has been applied. Enchantments have already been applied at this point, so this clamps the final damage value of critical hits.
destroy_on_hitBooleanfalseIf `true`, the projectile is removed when it deals damage to an entity.
destroy_on_hit_requires_damageBooleantrueIf `true`, `destroy_on_hit` only triggers when at least one point of damage is actually dealt (targets that fully absorb damage will not destroy the projectile).
set_last_hurt_requires_damageBooleantrueIf `true`, the projectile only registers as the last hurt-by source on the target when at least one point of damage is actually dealt.
apply_knockback_to_blocking_targetsBooleanfalseIf `true`, knockback is still applied to targets that successfully blocked the hit.
mob_effectObject—Applies one or more mob effects to the entity hit. Effects are described with an `effects` array of effect objects.
effectsList of object[]Array of effect objects. Each element may specify `effect` (name), `amplifier`, and per-difficulty durations `durationeasy`, `durationnormal`, `durationhard`.
particle_on_hitObject—Emits a particle effect at the impact location, optionally only for entity hits or only for non-entity hits.
particle_typeTextnone, bubble, bubblemanual, crit, blockforcefield, smoke, explode, evaporation, flame, candleflame, lava, largesmoke, reddust, risingborderdust, iconcrack, snowballpoof, largeexplode, hugeexplosion, breezewindexplosion, mobflame, heart, terrain, townaura, portal …"none"Particle type to spawn at the impact point.
on_entity_hitBooleanfalseIf `true`, particles are spawned when the projectile hits an entity.
on_other_hitBooleanfalseIf `true`, particles are spawned when the projectile hits something that is not an entity.
num_particlesInteger1Number of particles to spawn per hit.
particle_item_nameObject—Map from item identifier to a filter group, used to select an item icon for `iconcrack`-style particles based on context (e.g. the projectile's owner).
remove_on_hitObject—Removes the projectile from the world when it hits a block, entity, or (if `hit_water` is set) water.
spawn_aoe_cloudObject—Spawns an area effect cloud at the impact point that applies potion effects to entities inside it over time
potionInteger-1Aux value of the potion whose effects the cloud applies. When `-1`, the potion is taken from the projectile entity itself.
radiusDecimal0Initial radius (in blocks) of the cloud.
radius_on_useDecimal-1Amount the radius shrinks (or grows) each time the cloud applies its effects. `-1` keeps the radius unchanged.
durationInteger or Text0How long, in seconds, the cloud persists before disappearing.
particleTextnone, bubble, bubblemanual, crit, blockforcefield, smoke, explode, evaporation, flame, candleflame, lava, largesmoke, reddust, risingborderdust, iconcrack, snowballpoof, largeexplode, hugeexplosion, breezewindexplosion, mobflame, heart, terrain, townaura, portal …"mobspellambient"Particle effect emitted by the cloud.
affect_ownerBooleantrueIf `true`, the projectile's owner can be affected by the cloud.
reapplication_delayInteger0Number of ticks the cloud waits before re-applying its effects to the same entity.
spawn_chanceObject—Conditionally spawns one or two groups of entities at the impact location and optionally fires events on each spawned entity.
first_spawn_chanceDecimal0 to 10Percent chance (0-1.0) that the first group spawns.
second_spawn_chanceDecimal0 to 10Percent chance (0-1.0) that the second group spawns (rolled independently of the first).
first_spawn_countInteger0Number of entities spawned when the first roll succeeds.
second_spawn_countInteger0Number of entities spawned when the second roll succeeds.
spawn_definitionText—Identifier of the entity definition to spawn.
spawn_babyBooleanfalseIf `true`, spawned entities start as babies (where applicable).
on_spawnList of object[]Array of entity event triggers to fire on each spawned entity.
stick_in_groundObject—Causes the projectile to embed itself in the block it hits.
shake_timeDecimal0Duration in seconds for which the projectile visually shakes after sticking.
teleport_ownerObject—Teleports the projectile's owner to the impact location.
thrown_potion_effectObject—Applies the splash-potion effects of a thrown potion to nearby entities at the impact point.
effectInteger-1Aux value of the potion to apply.
wind_burst_on_hitObject—Releases an outward wind burst at the impact point that pushes nearby entities away.
hit_waterBooleanfalseIf `true`, the projectile treats water as a hit surface and stops on contact.

Example from the game files

This is how vanilla Shulker Bullet uses it in Minecraft Bedrock 1.26.60.5:

{
  "minecraft:projectile": {
    "anchor": "eye_height",
    "crit_particle_on_hurt": true,
    "homing": true,
    "destroy_on_hurt": true,
    "gravity": 0.05,
    "hit_sound": "bullet.hit",
    "on_hit": {
      "impact_damage": {
        "apply_knockback_to_blocking_targets": true,
        "damage": {
          "min": 4,
          "max": 4
        },
        "knockback": true
      },
      "mob_effect": {
        "effects": [
          {
            "amplifier": 0,
            "durationhard": 200,
            "effect": "levitation",
            "durationeasy": 200,
            "durationnormal": 200
          }
        ]
      },
      "particle_on_hit": {
        "on_other_hit": true,
        "particle_type": "largeexplode"
      },
      "remove_on_hit": {}
    },
    "offset": [
      0,
      -0.1,
      0
    ],
    "power": 1.6,
    "should_bounce": "if_no_damage_dealt",
    "uncertainty_base": 16,
    "uncertainty_multiplier": 4,
    "isolated_physics": false
  }
}

Used by 18

Vanilla entities with minecraft:projectile in their definition:

Related components