Package dev.cerus.maps.api
Class MapScreen
java.lang.Object
dev.cerus.maps.api.MapScreen
Represents an array of clientside maps that form a screen
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionMapScreen(int id, VersionAdapter versionAdapter, int w, int h)MapScreen(int id, VersionAdapter versionAdapter, int w, int h, ClientsideMap[][] mapArray) -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a markervoidRecalculate the hit box of this screenvoidRemove all markersvoiddespawnFrames(org.bukkit.entity.Player... players)Remove the framesvoiddestroyFrames(org.bukkit.entity.Player... players)int[][]Frame[][]intintgetId()org.bukkit.LocationintgetWidth()voidremoveMarker(Marker marker)Remove a markervoidsendFrames(org.bukkit.entity.Player... players)Send the frame updates to the playersvoidsendMaps(boolean full)Send the map data to all online playersvoidsendMaps(boolean full, Collection<? extends org.bukkit.entity.Player> players)Send the map data to the specified playersvoidsendMaps(boolean full, org.bukkit.entity.Player... players)Send the map data to the specified playersvoidsendMarkers(org.bukkit.entity.Player... players)voidsetFrameIds(int[][] frameIds)Deprecated.voidvoidsetHitBox(MapScreen.HitBox hitBox)voidsetLocation(org.bukkit.Location location)voidspawnFrames(org.bukkit.entity.Player... players)Spawn the framesvoiduseFastGraphics(boolean b)
-
Constructor Details
-
MapScreen
-
MapScreen
-
-
Method Details
-
addMarker
Add a marker- Parameters:
marker- The marker to add
-
removeMarker
Remove a marker- Parameters:
marker- The marker to remove
-
clearMarkers
public void clearMarkers()Remove all markers -
sendMaps
public void sendMaps(boolean full)Send the map data to all online players- Parameters:
full- True if full map data should be sent
-
sendMaps
Send the map data to the specified players- Parameters:
full- True if full map data should be sentplayers- The receivers
-
sendMaps
public void sendMaps(boolean full, org.bukkit.entity.Player... players)Send the map data to the specified players- Parameters:
full- True if full map data should be sentplayers- The receivers
-
sendMarkers
public void sendMarkers(org.bukkit.entity.Player... players) -
sendFrames
public void sendFrames(org.bukkit.entity.Player... players)Send the frame updates to the players- Parameters:
players- The receivers
-
spawnFrames
public void spawnFrames(org.bukkit.entity.Player... players)Spawn the frames- Parameters:
players- The receivers
-
despawnFrames
public void despawnFrames(org.bukkit.entity.Player... players)Remove the frames- Parameters:
players- The receivers
-
destroyFrames
public void destroyFrames(org.bukkit.entity.Player... players) -
getId
public int getId() -
getWidth
public int getWidth() -
getHeight
public int getHeight() -
useFastGraphics
public void useFastGraphics(boolean b) -
getGraphics
-
getFrames
-
setFrames
-
getFrameIds
public int[][] getFrameIds() -
setFrameIds
Deprecated. -
getMarkers
-
getLocation
public org.bukkit.Location getLocation() -
setLocation
public void setLocation(org.bukkit.Location location) -
calculateHitBox
public void calculateHitBox()Recalculate the hit box of this screen -
getHitBox
-
setHitBox
-