Package net.glowstone
Class Explosion
java.lang.Object
net.glowstone.Explosion
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
-
Constructor Summary
ConstructorDescriptionExplosion
(org.bukkit.entity.Entity source, GlowWorld world, double x, double y, double z, float power, boolean incendiary, boolean breakBlocks) Creates a new explosion.Explosion
(org.bukkit.entity.Entity source, org.bukkit.Location location, float power, boolean incendiary, boolean breakBlocks) Creates a new explosion. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Explodes, firing aEntityExplodeEvent
, as long as its power is non-negligible.
-
Field Details
-
POWER_TNT
public static final int POWER_TNT- See Also:
-
POWER_BED
public static final int POWER_BED- See Also:
-
POWER_CREEPER
public static final int POWER_CREEPER- See Also:
-
POWER_CHARGED_CREEPER
public static final int POWER_CHARGED_CREEPER- See Also:
-
POWER_GHAST
public static final int POWER_GHAST- See Also:
-
POWER_WITHER_SKULL
public static final int POWER_WITHER_SKULL- See Also:
-
POWER_WITHER_CREATION
public static final int POWER_WITHER_CREATION- See Also:
-
POWER_ENDER_CRYSTAL
public static final int POWER_ENDER_CRYSTAL- See Also:
-
EXPLOSION_VISIBILITY_RADIUS
public static final int EXPLOSION_VISIBILITY_RADIUS- See Also:
-
-
Constructor Details
-
Explosion
public Explosion(org.bukkit.entity.Entity source, GlowWorld world, double x, double y, double z, float power, boolean incendiary, boolean breakBlocks) Creates a new explosion.- Parameters:
source
- The entity causing this explosionworld
- The world this explosion is inx
- The X location of the explosiony
- The Y location of the explosionz
- The Z location of the explosionpower
- The power of the explosionincendiary
- Whether or not blocks should be set on firebreakBlocks
- Whether blocks should break through this explosion
-
Explosion
public Explosion(@Nullable org.bukkit.entity.Entity source, org.bukkit.Location location, float power, boolean incendiary, boolean breakBlocks) Creates a new explosion.- Parameters:
source
- The entity causing this explosionlocation
- The location this explosion is occuring at. Must be in a GlowWorld.power
- The power of the explosionincendiary
- Whether or not blocks should be set on firebreakBlocks
- Whether blocks should break through this explosion
-
-
Method Details
-
explodeWithEvent
public boolean explodeWithEvent()Explodes, firing aEntityExplodeEvent
, as long as its power is non-negligible.- Returns:
- false if the explosion was canceled by a plugin; true otherwise
-