Class WbsParticleGroup

java.lang.Object
wbs.utils.util.particles.WbsParticleGroup

public class WbsParticleGroup extends Object
Class to support multiple WbsParticleEffects with predefined particles running at the same time and 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 play
      particle - The particle to use when playing the given effect
      chance - The chance for the
      Returns:
      The same particle group
    • addEffect

      public WbsParticleGroup addEffect(WbsParticleEffect effect, org.bukkit.Particle particle)
      Add an effect to play 100% of the time
      Parameters:
      effect - The effect to play
      particle - 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

      public WbsParticleEffect playRandom(org.bukkit.Location location)
      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

      public WbsParticleGroup clone()
      Overrides:
      clone in class Object