PacketModelEntity

public interface PacketModelEntity implements PacketEntityInterface

Inheritors

Functions

Link copied to clipboard
public void clearBrightness()
Drops the fixed light level, so the display takes the light at its position again.
public abstract AbstractPacketBundle generateLocationAndRotationAndScalePackets(AbstractPacketBundle packetBundle, Location location, EulerAngle eulerAngle, float scale)
public AbstractPacketBundle generateLocationAndRotationAndScalePackets(AbstractPacketBundle packetBundle, Location location, EulerAngle eulerAngle, float scaleX, float scaleY, float scaleZ)
Link copied to clipboard
public void generateRiddenTransformationPackets(AbstractPacketBundle packetBundle, Location seat, Vector3f translation, EulerAngle eulerAngle, float scaleX, float scaleY, float scaleZ, int interpolationTicks)
Pose of a display that rides another entity.
Link copied to clipboard
public abstract boolean hasViewers()
Link copied to clipboard
public void initializeModel(Location location, int modelID)
public void initializeModel(Location location, String modelID)
Link copied to clipboard
public void queueMetadataUpdate(AbstractPacketBundle packetBundle)
Adds the pending metadata changes for current viewers to the bundle.
Link copied to clipboard
public abstract void sendLocationAndRotationAndScalePacket(Location location, EulerAngle eulerAngle, float scale)
public void sendLocationAndRotationAndScalePacket(Location location, EulerAngle eulerAngle, float scaleX, float scaleY, float scaleZ)
Link copied to clipboard
public abstract void sendLocationAndRotationPacket(Location location, EulerAngle eulerAngle)
Link copied to clipboard
public void setBillboard(Display.Billboard billboard)
Link copied to clipboard
public void setBrightness(int blockLight, int skyLight)
Fixed light level, 0 to 15, in place of the light at the entity's position.
Link copied to clipboard
public void setCullingBox(float width, float height)
Box viewers test against their view to skip drawing this display while it is off screen: width across, centred on the entity, and height up from its position, in blocks; a negative height hangs the box down from the position instead.
Link copied to clipboard
public abstract void setHorseLeatherArmorColor(Color color)
Link copied to clipboard
public void setItemModel(String modelID, Color tint)
Swaps the displayed item model and its custom-model-data tint.
Link copied to clipboard
public abstract void setScale(float scale)
Link copied to clipboard
public void setTeleportDuration(int ticks)
How many ticks viewers take to glide to a new position after a move.
Link copied to clipboard
public void setTransformation(Vector3f translation, Quaternionf leftRotation, Vector3f scale, int interpolationTicks)
Sets translation, left rotation and scale.
Link copied to clipboard
public void setViewRange(float range)
Link copied to clipboard
public boolean supportsRiddenPlacement()
True when viewers can place this display as a passenger of another entity through its transformation.

Inherited functions

Link copied to clipboard
public abstract void addRemoveCallback(Runnable callback)
Link copied to clipboard
public abstract void addViewer(UUID uuid)
Link copied to clipboard
Link copied to clipboard
public void dismount()
Dismounts this packet entity from any vehicle.
public void dismount(AbstractPacketBundle bundle)
Bundled dismount, like mountTo.
Link copied to clipboard
public abstract void displayTo(UUID uuid)
Link copied to clipboard
public B getBukkitEntity<B extends Entity>()
Gets the underlying Bukkit entity for direct modification.
Link copied to clipboard
public int getEntityId()
Gets the entity ID of this packet entity.
Link copied to clipboard
public abstract Location getLocation()
Link copied to clipboard
public abstract UUID getUniqueId()
Link copied to clipboard
public void handleInteraction(Player player, boolean isAttack)
Called internally when a player interacts with this packet entity.
public void handleInteraction(Player player, PacketInteractionContext context)
Called internally with the exact decoded packet action and hand.
Link copied to clipboard
public abstract void hideFrom(UUID uuid)
Link copied to clipboard
public void mountTo(int vehicleEntityId)
Makes this packet entity ride another entity (the vehicle).
public void mountTo(int vehicleEntityId, AbstractPacketBundle bundle)
Bundled mount: adds each viewer's passenger list to bundle instead of sending it, so entities that mount the same vehicle together reach each viewer in one bundle.
Link copied to clipboard
public abstract void remove()
Link copied to clipboard
public abstract void removeViewer(UUID uuid)
Link copied to clipboard
Sets a left-click callback that receives the decoded interaction context.
Link copied to clipboard
Sets a right-click callback that receives the decoded action and hand.
Link copied to clipboard
public void setLeftClickCallback(BiConsumer<Player, PacketEntityInterface> callback)
Sets a callback to be invoked when a player left-clicks (attacks) this packet entity.
Link copied to clipboard
public void setRightClickCallback(BiConsumer<Player, PacketEntityInterface> callback)
Sets a callback to be invoked when a player right-clicks (interacts with) this packet entity.
Link copied to clipboard
public abstract void setVisible(boolean visible)
Link copied to clipboard
public void syncMetadata()
Syncs entity metadata to all viewers.
Link copied to clipboard
public abstract void teleport(Location location)

public void teleport(Location location, AbstractPacketBundle bundle)
Bundled teleport: adds this entity's position update to the given packet bundle instead of sending it directly, so per-tick movers (e.g.