Class ParticleStyleRegistrationEvent

java.lang.Object
org.bukkit.event.Event
dev.esophose.playerparticles.event.ParticleStyleRegistrationEvent

public class ParticleStyleRegistrationEvent
extends org.bukkit.event.Event
An event that gets called during the PlayerParticles style registration
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.bukkit.event.Event

    org.bukkit.event.Event.Result
  • Constructor Summary

    Constructors 
    Constructor Description
    ParticleStyleRegistrationEvent()  
  • Method Summary

    Modifier and Type Method Description
    static org.bukkit.event.HandlerList getHandlerList()  
    org.bukkit.event.HandlerList getHandlers()  
    java.util.Map<java.lang.String,​ParticleStyle> getRegisteredEventStyles()  
    java.util.Map<java.lang.String,​ParticleStyle> getRegisteredStyles()  
    boolean registerEventStyle​(ParticleStyle style)
    Registers an event-based ParticleStyle, overwriting any existing styles with the same name.
    boolean registerStyle​(ParticleStyle style)
    Registers a ParticleStyle, overwriting any existing styles with the same name
    boolean unregisterStyle​(java.lang.String internalName)
    Unregisters a ParticleStyle

    Methods inherited from class org.bukkit.event.Event

    getEventName, isAsynchronous

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • getRegisteredStyles

      public java.util.Map<java.lang.String,​ParticleStyle> getRegisteredStyles()
      Returns:
      An unmodifiable map of registered styles keyed by the style internal name
    • getRegisteredEventStyles

      public java.util.Map<java.lang.String,​ParticleStyle> getRegisteredEventStyles()
      Returns:
      An unmodifiable map of registered event styles keyed by the style internal name
    • registerStyle

      public boolean registerStyle​(ParticleStyle style)
      Registers a ParticleStyle, overwriting any existing styles with the same name
      Parameters:
      style - The ParticleStyle to register
      Returns:
      true if registered without replacing an existing style, false if an existing style was replaced
    • registerEventStyle

      public boolean registerEventStyle​(ParticleStyle style)
      Registers an event-based ParticleStyle, overwriting any existing styles with the same name. Styles registered with this method bypass the normal update loop, and must instead be spawned manually.
      Parameters:
      style - The ParticleStyle to register
      Returns:
      true if registered without replacing an existing style, false if an existing style was replaced
    • unregisterStyle

      public boolean unregisterStyle​(java.lang.String internalName)
      Unregisters a ParticleStyle
      Parameters:
      internalName - The internal name of the ParticleStyle to unregister
      Returns:
      true if a style was unregistered, false otherwise
    • getHandlers

      public org.bukkit.event.HandlerList getHandlers()
      Specified by:
      getHandlers in class org.bukkit.event.Event
    • getHandlerList

      public static org.bukkit.event.HandlerList getHandlerList()