Package dev.cerus.maps.api.version
Interface VersionAdapter
public interface VersionAdapter
Interface for version specific code
-
Method Summary
Modifier and TypeMethodDescriptionvoid
inject(org.bukkit.entity.Player player, PacketListener listener, org.bukkit.plugin.java.JavaPlugin plugin)
Inject a packet listener into the players connectionmakeFrameDespawnPacket(Frame frame)
Make a frame despawn packetmakeFramePacket(int frameId, boolean visible, ClientsideMap map)
Make a frame update packet to display fake itemsdefault Object
makeFramePacket(int frameId, ClientsideMap map)
makeFrameSpawnPacket(Frame frame)
Make a frame spawn packetmakeMapPacket(boolean ignoreBounds, ClientsideMap map)
Make a packet to send a map to a playervoid
sendPacket(org.bukkit.entity.Player player, Object packet)
Send a packet to a playe
-
Method Details
-
makeMapPacket
Make a packet to send a map to a player- Parameters:
ignoreBounds
- If true, implementations should use the full buffer and ignore the boundsmap
- The map- Returns:
- The new packet
-
makeFramePacket
Make a frame update packet to display fake items- Parameters:
frameId
- The id of the framemap
- The map to display- Returns:
- The new packet
-
makeFramePacket
-
makeFrameSpawnPacket
Make a frame spawn packet- Parameters:
frame
- The frame to spawn- Returns:
- The spawn packet
-
makeFrameDespawnPacket
Make a frame despawn packet- Parameters:
frame
- The frame to despawn- Returns:
- The despawn packet
-
sendPacket
Send a packet to a playe- Parameters:
player
- The playerpacket
- The packet
-
inject
void inject(org.bukkit.entity.Player player, PacketListener listener, org.bukkit.plugin.java.JavaPlugin plugin)Inject a packet listener into the players connection- Parameters:
player
- The player to injectlistener
- The listener
-