Package wbs.utils.util.particles
Class WbsParticleGroup
java.lang.Object
wbs.utils.util.particles.WbsParticleGroup
Class to support multiple WbsParticleEffects with predefined particles
running at the same time and location.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddEffect(WbsParticleEffect effect, org.bukkit.Particle particle) Add an effect to play 100% of the timeaddEffect(WbsParticleEffect effect, org.bukkit.Particle particle, double chance) Add an effect to play with a given chanceclone()voidplay(org.bukkit.Location location) Play all effects at a given location.voidplay(org.bukkit.Location location, org.bukkit.Location finishLocation) Play all effects at a given location.playRandom(org.bukkit.Location location) Play a random effect from this group at the given location.playRandom(org.bukkit.Location location, org.bukkit.Location finishLocation) Play a random effect from this group at the given location.
-
Constructor Details
-
WbsParticleGroup
public WbsParticleGroup()
-
-
Method Details
-
addEffect
public WbsParticleGroup addEffect(WbsParticleEffect effect, org.bukkit.Particle particle, double chance) Add an effect to play with a given chance- Parameters:
effect- The effect to playparticle- The particle to use when playing the given effectchance- The chance for the- Returns:
- The same particle group
-
addEffect
Add an effect to play 100% of the time- Parameters:
effect- The effect to playparticle- The particle to use when playing the given effect- Returns:
- The same particle group
-
play
public void play(org.bukkit.Location location) Play all effects at a given location.- Parameters:
location- The location to play the effects at.
-
play
public void play(org.bukkit.Location location, org.bukkit.Location finishLocation) Play all effects at a given location.- Parameters:
location- The location to play the effects at.finishLocation- The location to use as the end point if the effect is a line.
-
playRandom
Play a random effect from this group at the given location.- Parameters:
location- The location to play the effect at.- Returns:
- The randomly chosen effect.
-
playRandom
public WbsParticleEffect playRandom(org.bukkit.Location location, org.bukkit.Location finishLocation) Play a random effect from this group at the given location.- Parameters:
location- The location to play the effect at.finishLocation- The location to use as the end point if the effect is a line.- Returns:
- The randomly chosen effect.
-
clone
-