Class FireworkEffect
java.lang.Object
org.bukkit.FireworkEffect
- All Implemented Interfaces:
ConfigurationSerializable
Represents a single firework effect.
- Since:
- 1.4.6
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classThis is a builder for FireworkEffects.static enumThe type or shape of the effect. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull FireworkEffect.Builderbuilder()Construct a firework effect.static @NotNull ConfigurationSerializabledeserialize(@NotNull Map<String, Object> map) booleanGet the primary colors of the firework effect.Get the fade colors of the firework effect.@NotNull FireworkEffect.TypegetType()Get the type of the firework effect.booleanGet whether the firework effect flickers.inthashCode()booleanhasTrail()Get whether the firework effect has a trail.Creates a Map representation of this class.toString()
-
Method Details
-
builder
Construct a firework effect.- Returns:
- A utility object for building a firework effect
- Since:
- 1.4.6
-
hasFlicker
public boolean hasFlicker()Get whether the firework effect flickers.- Returns:
- true if it flickers, false if not
- Since:
- 1.4.6
-
hasTrail
public boolean hasTrail()Get whether the firework effect has a trail.- Returns:
- true if it has a trail, false if not
- Since:
- 1.4.6
-
getColors
-
getFadeColors
-
getType
Get the type of the firework effect.- Returns:
- The effect type
- Since:
- 1.4.6
-
deserialize
@NotNull public static @NotNull ConfigurationSerializable deserialize(@NotNull @NotNull Map<String, Object> map) - Parameters:
map- the map to deserialize- Returns:
- the resulting serializable
- Since:
- 1.4.6
- See Also:
-
serialize
Description copied from interface:ConfigurationSerializableCreates a Map representation of this class.This class must provide a method to restore this class, as defined in the
ConfigurationSerializableinterface javadocs. nb: It is not intended for this method to be called directly, this will be called by theConfigurationSerializationclass.- Specified by:
serializein interfaceConfigurationSerializable- Returns:
- Map containing the current state of this class
- Since:
- 1.4.6
-
toString
-
hashCode
-
equals
-