Enum ParticleEffect
java.lang.Object
java.lang.Enum<ParticleEffect>
dev.esophose.playerparticles.particles.ParticleEffect
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<ParticleEffect>
,java.lang.constant.Constable
public enum ParticleEffect extends java.lang.Enum<ParticleEffect>
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ParticleEffect.ParticleProperty
Represents the property of a particle effect -
Enum Constant Summary
-
Method Summary
Modifier and Type Method Description void
display(double offsetX, double offsetY, double offsetZ, double speed, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)
Displays a particle effectvoid
display(ColorTransition colorTransition, double offsetX, double offsetY, double offsetZ, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner, float size)
Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param centervoid
display(ParticleColor color, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner, float size)
Displays a single particle which is coloredvoid
display(Vibration vibration, double offsetX, double offsetY, double offsetZ, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)
Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param centerstatic void
display(ParticlePair particle, PParticle pparticle, boolean isLongRange, org.bukkit.entity.Player owner)
Invokes the correct spawn method for the particle information givenvoid
display(org.bukkit.Material spawnMaterial, double offsetX, double offsetY, double offsetZ, double speed, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)
Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param centerstatic ParticleEffect
fromInternalName(java.lang.String internalName)
Returns the particle effect with the given namestatic ParticleEffect
fromName(java.lang.String name)
Returns the particle effect with the given namestatic java.util.List<ParticleEffect>
getEnabledEffects()
Returns a ParticleEffect List of all enabled effects for the server versionorg.bukkit.Material
getGuiIconMaterial()
java.lang.String
getInternalName()
java.lang.String
getName()
org.bukkit.Particle
getSpigotEnum()
boolean
hasProperties()
boolean
hasProperty(ParticleEffect.ParticleProperty property)
Determine if this particle effect has a specific propertyboolean
isEnabled()
boolean
isSupported()
Determine if this particle effect is supported by the current server versionvoid
loadSettings(boolean reloadConfig)
Loads the settings shared for each style then calls loadSettings(CommentedFileConfiguration)static void
reloadSettings()
Reloads the settings for all ParticleEffectsstatic ParticleEffect
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ParticleEffect[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
AMBIENT_ENTITY_EFFECT
-
ANGRY_VILLAGER
-
ASH
-
BARRIER
-
BLOCK
-
BLOCK_MARKER
-
BUBBLE
-
BUBBLE_COLUMN_UP
-
BUBBLE_POP
-
CAMPFIRE_COSY_SMOKE
-
CAMPFIRE_SIGNAL_SMOKE
-
CLOUD
-
COMPOSTER
-
CRIMSON_SPORE
-
CRIT
-
CURRENT_DOWN
-
DAMAGE_INDICATOR
-
DOLPHIN
-
DRAGON_BREATH
-
DRIPPING_DRIPSTONE_LAVA
-
DRIPPING_DRIPSTONE_WATER
-
DRIPPING_HONEY
-
DRIPPING_LAVA
-
DRIPPING_OBSIDIAN_TEAR
-
DRIPPING_WATER
-
DUST
-
DUST_COLOR_TRANSITION
-
ELDER_GUARDIAN
-
ELECTRIC_SPARK
-
ENCHANT
-
ENCHANTED_HIT
-
END_ROD
-
ENTITY_EFFECT
-
EXPLOSION
-
EXPLOSION_EMITTER
-
FALLING_DRIPSTONE_LAVA
-
FALLING_DRIPSTONE_WATER
-
FALLING_DUST
-
FALLING_HONEY
-
FALLING_LAVA
-
FALLING_NECTAR
-
FALLING_OBSIDIAN_TEAR
-
FALLING_SPORE_BLOSSOM
-
FALLING_WATER
-
FIREWORK
-
FISHING
-
FLAME
-
FLASH
-
GLOW
-
GLOW_SQUID_INK
-
FOOTSTEP
-
HAPPY_VILLAGER
-
HEART
-
INSTANT_EFFECT
-
ITEM
-
ITEM_SLIME
-
ITEM_SNOWBALL
-
LANDING_HONEY
-
LANDING_LAVA
-
LANDING_OBSIDIAN_TEAR
-
LARGE_SMOKE
-
LAVA
-
LIGHT
-
MYCELIUM
-
NAUTILUS
-
NOTE
-
POOF
-
PORTAL
-
RAIN
-
REVERSE_PORTAL
-
SCRAPE
-
SMALL_FLAME
-
SMOKE
-
SNEEZE
-
SNOWFLAKE
-
SOUL
-
SOUL_FIRE_FLAME
-
SPELL
-
SPIT
-
SPLASH
-
SPORE_BLOSSOM_AIR
-
SQUID_INK
-
SWEEP_ATTACK
-
TOTEM_OF_UNDYING
-
UNDERWATER
-
VIBRATION
-
WARPED_SPORE
-
WAX_OFF
-
WAX_ON
-
WHITE_ASH
-
WITCH
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
loadSettings
public void loadSettings(boolean reloadConfig)Loads the settings shared for each style then calls loadSettings(CommentedFileConfiguration)- Parameters:
reloadConfig
- If the settings should be reloaded or not
-
reloadSettings
public static void reloadSettings()Reloads the settings for all ParticleEffects -
getInternalName
public java.lang.String getInternalName()- Returns:
- the internal name of this particle effect that will never change
-
getName
public java.lang.String getName()- Returns:
- the name that the style will display to the users as
-
getSpigotEnum
public org.bukkit.Particle getSpigotEnum()- Returns:
- the Spigot enum this represents
-
getGuiIconMaterial
public org.bukkit.Material getGuiIconMaterial()- Returns:
- The Material icon that represents this style in the GUI
-
hasProperty
Determine if this particle effect has a specific property- Parameters:
property
- The property to check- Returns:
- Whether it has the property or not
-
hasProperties
public boolean hasProperties()- Returns:
- true if this effect has any properties
-
isSupported
public boolean isSupported()Determine if this particle effect is supported by the current server version- Returns:
- Whether the particle effect is supported or not
-
isEnabled
public boolean isEnabled()- Returns:
- true if this effect is enabled, otherwise false
-
getEnabledEffects
Returns a ParticleEffect List of all enabled effects for the server version- Returns:
- Enabled effects
-
fromName
Returns the particle effect with the given name- Parameters:
name
- Name of the particle effect- Returns:
- The particle effect
-
fromInternalName
Returns the particle effect with the given name- Parameters:
internalName
- Internal name of the particle effect- Returns:
- The particle effect
-
display
public static void display(ParticlePair particle, PParticle pparticle, boolean isLongRange, org.bukkit.entity.Player owner)Invokes the correct spawn method for the particle information given- Parameters:
particle
- The ParticlePair, given the effect/style/datapparticle
- The particle spawn informationisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particles
-
display
public void display(double offsetX, double offsetY, double offsetZ, double speed, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)Displays a particle effect- Parameters:
offsetX
- Maximum distance particles can fly away from the center on the x-axisoffsetY
- Maximum distance particles can fly away from the center on the y-axisoffsetZ
- Maximum distance particles can fly away from the center on the z-axisspeed
- Display speed of the particlesamount
- Amount of particlescenter
- Center location of the effectisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particles- Throws:
ParticleSpawner.ParticleDataException
- If the particle effect requires additional data
-
display
public void display(ParticleColor color, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner, float size)Displays a single particle which is colored- Parameters:
color
- Color of the particlecenter
- Center location of the effectisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particlessize
- The size of the particles- Throws:
ParticleSpawner.ParticleColorException
- If the particle effect is not colorable or the color type is incorrect
-
display
public void display(org.bukkit.Material spawnMaterial, double offsetX, double offsetY, double offsetZ, double speed, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param center- Parameters:
spawnMaterial
- Material of the effectoffsetX
- Maximum distance particles can fly away from the center on the x-axisoffsetY
- Maximum distance particles can fly away from the center on the y-axisoffsetZ
- Maximum distance particles can fly away from the center on the z-axisspeed
- Display speed of the particlesamount
- Amount of particlescenter
- Center location of the effectisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particles- Throws:
ParticleSpawner.ParticleDataException
- If the particle effect does not require additional data or if the data type is incorrect
-
display
public void display(ColorTransition colorTransition, double offsetX, double offsetY, double offsetZ, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner, float size)Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param center- Parameters:
colorTransition
- Color transition of the effectoffsetX
- Maximum distance particles can fly away from the center on the x-axisoffsetY
- Maximum distance particles can fly away from the center on the y-axisoffsetZ
- Maximum distance particles can fly away from the center on the z-axisamount
- Amount of particlescenter
- Center location of the effectisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particlessize
- The size of the particles- Throws:
ParticleSpawner.ParticleDataException
- If the particle effect does not require additional data or if the data type is incorrect
-
display
public void display(Vibration vibration, double offsetX, double offsetY, double offsetZ, int amount, org.bukkit.Location center, boolean isLongRange, org.bukkit.entity.Player owner)Displays a particle effect which requires additional data and is only visible for all players within a certain range in the world of @param center- Parameters:
vibration
- Vibration of the effectoffsetX
- Maximum distance particles can fly away from the center on the x-axisoffsetY
- Maximum distance particles can fly away from the center on the y-axisoffsetZ
- Maximum distance particles can fly away from the center on the z-axisamount
- Amount of particlescenter
- Center location of the effectisLongRange
- If the particle can be viewed from long rangeowner
- The player that owns the particles- Throws:
ParticleSpawner.ParticleDataException
- If the particle effect does not require additional data or if the data type is incorrect
-