Package org.bukkit.map
Interface MapPalette.MapColorCache
- Enclosing class:
MapPalette
public static interface MapPalette.MapColorCache
Holds cached information for matching map colors of a given RBG color.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isCached()
Returns true if the MapColorCache has values cached, if not it will return false.byte
matchColor
(Color color) Deprecated.Magic value
-
Method Details
-
isCached
boolean isCached()Returns true if the MapColorCache has values cached, if not it will return false. A case where it might return false is when the cache is not build jet.- Returns:
- true if this MapColorCache has values cached otherwise false
-
matchColor
Deprecated.Magic valueGet the cached index of the closest matching color in the palette to the given color.- Parameters:
color
- The Color to match.- Returns:
- The index in the palette.
- Throws:
IllegalStateException
- ifisCached()
returns false
-