Class Sprite

java.lang.Object
dev.cerus.maps.api.font.Sprite

public class Sprite extends Object
Represents a single character / codepoint
  • Constructor Details

    • Sprite

      public Sprite(int width, int height)
    • Sprite

      public Sprite(int width, int height, boolean[] grid)
  • Method Details

    • fromBukkit

      public static Sprite fromBukkit(org.bukkit.map.MapFont.CharacterSprite bukkitSprite)
      Convert Bukkit sprite into maps sprite
      Parameters:
      bukkitSprite - The Bukkit sprite
      Returns:
      The converted sprite
    • get

      public boolean get(int row, int col)
      Get a pixel
      Parameters:
      row - The row
      col - The column
      Returns:
      The pixel (true = visible, false = invisible)
    • getWidth

      public int getWidth()
    • getHeight

      public int getHeight()
    • getGrid

      public boolean[] getGrid()