Package journeymap.api.v2.client.display
Class MarkerOverlay
java.lang.Object
journeymap.api.v2.client.display.Displayable
journeymap.api.v2.client.display.Overlay
journeymap.api.v2.client.display.MarkerOverlay
- All Implemented Interfaces:
Comparable<Displayable>
A Marker overlay shows a geographical point on the map with an icon and a label.
For example: A pushpin shown at the world spawn point.
Setters use the Builder pattern so they can be chained.
Note that like all Displayables, simply changing this object doesn't guarantee the player will get the changes.
You must call IClientAPI.show(Displayable) in order for the changes to take effect
in JourneyMap.
-
Field Summary
Fields inherited from class journeymap.api.v2.client.display.Overlay
activeMapTypes, activeUIs, dimension, displayOrder, label, maxZoom, minZoom, needsRerender, overlayGroupName, overlayListener, textProperties, titleFields inherited from class journeymap.api.v2.client.display.Displayable
displayType, id, modId -
Constructor Summary
ConstructorsConstructorDescriptionMarkerOverlay(String modId, net.minecraft.core.BlockPos point, MapImage icon) Constructor. -
Method Summary
Methods inherited from class journeymap.api.v2.client.display.Overlay
clearFlagForRerender, flagForRerender, getActiveMapTypes, getActiveUIs, getDimension, getDisplayOrder, getLabel, getMaxZoom, getMinZoom, getNeedsRerender, getOverlayGroupName, getOverlayListener, getTextProperties, getTitle, isActiveIn, isInZoomRange, setActiveMapTypes, setActiveUIs, setDimension, setDisplayOrder, setLabel, setMaxZoom, setMinZoom, setOverlayGroupName, setOverlayListener, setTextProperties, setTitle, toStringHelperMethods inherited from class journeymap.api.v2.client.display.Displayable
clampOpacity, clampRGB, compareTo, equals, getDisplayType, getGuid, getId, getModId, hashCode
-
Constructor Details
-
MarkerOverlay
Constructor.- Parameters:
modId- Your mod id.point- Location of the marker.icon- The icon to display as the marker.
-
-
Method Details
-
getPoint
public net.minecraft.core.BlockPos getPoint()Location of the marker. -
setPoint
Sets the location of the marker.- Parameters:
point- location- Returns:
- this
-
getIcon
Icon to display in the marker.- Returns:
- icon
-
setIcon
Sets the icon to display in the marker.- Parameters:
icon- marker image- Returns:
- this
-
toString
-