Interface IOverlayHandler


  • public interface IOverlayHandler
    Manages skin overlays applied to an entity or player. Overlays are indexed by ID and rendered on top of the base skin.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void add​(int id, ISkinOverlay overlay)
      Adds or replaces an overlay at the given ID.
      void clear()
      Removes all overlays.
      ISkinOverlay get​(int id)
      Returns the overlay at the given ID.
      boolean has​(int id)
      Checks whether an overlay exists at the given ID.
      boolean remove​(int id)
      Removes the overlay at the given ID.
      int size()
      Returns the number of active overlays.
    • Method Detail

      • add

        void add​(int id,
                 ISkinOverlay overlay)
        Adds or replaces an overlay at the given ID.
        Parameters:
        id - the overlay ID.
        overlay - the skin overlay to add.
      • get

        ISkinOverlay get​(int id)
        Returns the overlay at the given ID.
        Parameters:
        id - the overlay ID.
        Returns:
        the skin overlay, or null if not found.
      • has

        boolean has​(int id)
        Checks whether an overlay exists at the given ID.
        Parameters:
        id - the overlay ID.
        Returns:
        true if an overlay exists; false otherwise.
      • remove

        boolean remove​(int id)
        Removes the overlay at the given ID.
        Parameters:
        id - the overlay ID.
        Returns:
        true if an overlay was removed; false otherwise.
      • size

        int size()
        Returns the number of active overlays.
        Returns:
        the overlay count.
      • clear

        void clear()
        Removes all overlays.