跳转至

Explode

文档版本:1.21.50.25

Defines how the entity explodes.

架构

explode:
{
  boolean "allow_underwater" : opt
  boolean "breaks_blocks" : opt
  boolean "causes_fire" : opt
  number "damage_scaling" : opt
  boolean "destroy_affected_by_griefing" : opt
  boolean "fire_affected_by_griefing" : opt
  array "fuse_length" : opt
  {
    number "0..0" : opt
    number "1..1" : opt
  }
  number "fuse_length" : opt
  boolean "fuse_lit" : opt
  number "knockback_scaling" : opt
  number "max_resistance" : opt
  boolean "negates_fall_damage" : opt
  string "particle_effect" : opt
  number "power" : opt
  string "sound_effect" : opt
  boolean "toggles_blocks" : opt
}
allow_underwaterboolean
If true, the explosion will affect blocks and entities under water.
breaks_blocksboolean
If true, the explosion will destroy blocks in the explosion radius.
causes_fireboolean
If true, blocks in the explosion radius will be set on fire.
damage_scalingnumber
A scale factor applied to the explosion's damage to entities. A value of 0 prevents the explosion from dealing any damage. Negative values cause the explosion to heal entities instead.
destroy_affected_by_griefingboolean
If true, whether the explosion breaks blocks is affected by the mob griefing game rule.
fire_affected_by_griefingboolean
If true, whether the explosion causes fire is affected by the mob griefing game rule.
fuse_lengtharray
The range for the random amount of time the fuse will be lit before exploding, a negative value means the explosion will be immediate.
fuse_length
0..0number
1..1number
fuse_lengthnumber
The range for the random amount of time the fuse will be lit before exploding, a negative value means the explosion will be immediate.
fuse_litboolean
If true, the fuse is already lit when this component is added to the entity.
knockback_scalingnumber
A scale factor applied to the knockback force caused by the explosion.
max_resistancenumber
A blocks explosion resistance will be capped at this value when an explosion occurs.
negates_fall_damageboolean
Defines whether the explosion should apply fall damage negation to Players above the point of collision.
particle_effectstring
The name of the particle effect to use.
powernumber
The radius of the explosion in blocks and the amount of damage the explosion deals.
sound_effectstring
The name of the sound effect played when the explosion triggers.
toggles_blocksboolean
If true, the explosion will toggle blocks in the explosion radius.