Package org.spongepowered.api.item
Interface FireworkEffect
- All Superinterfaces:
DataSerializable
Represents a firework explosion.
FireworkEffect
s are immutable once created. To change one
or create one, use FireworkEffect.Builder
.
-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic FireworkEffect.Builder
builder()
Creates a newFireworkEffect.Builder
to build aFireworkEffect
.colors()
Gets the ordered list of colors.Gets the ordered list of colors.boolean
flickers()
Gets whether thisFireworkEffect
will flicker when detonated.boolean
hasTrail()
Gets whether thisFireworkEffect
will have a trail when detonated.shape()
Gets the explosion shape.Methods inherited from interface org.spongepowered.api.data.persistence.DataSerializable
contentVersion, toContainer
-
Method Details
-
builder
Creates a newFireworkEffect.Builder
to build aFireworkEffect
.- Returns:
- The new builder
-
flickers
boolean flickers()Gets whether thisFireworkEffect
will flicker when detonated.- Returns:
- Whether this effect will flicker
-
hasTrail
boolean hasTrail()Gets whether thisFireworkEffect
will have a trail when detonated.- Returns:
- Whether this effect will have a trail
-
colors
Gets the ordered list of colors.In some implementations, the order of colors defines the colors showing from edge to center of the firework explosion.
- Returns:
- The list of colors
-
fadeColors
Gets the ordered list of colors.Normally in vanilla, the order of colors defines the colors showing from edge to center of the firework explosion.
- Returns:
- The list of colors
-
shape
FireworkShape shape()Gets the explosion shape.- Returns:
- The explosion shape
-