EntityManagerHub

Hub interface for packet-based entity management.

Provides methods for creating fake entities, managing entity visibility, and faking animations and metadata updates for existing entities.

Inheritors

Functions

Link copied to clipboard
abstract fun createFakeEntityBuilder(player: Player, type: EntityType, location: Location): FakeEntityBuilder

Creates a new FakeEntityBuilder for faking an entity to the player.

Link copied to clipboard
abstract fun fakePlayerName(player: Player, target: Player, name: String)

Fakes the display name of a player in the tab list or above their head.

Link copied to clipboard
abstract fun hideEntity(player: Player, entityId: Int)

Hides an entity from the player via a packet.

Link copied to clipboard
abstract fun sendMetadata(player: Player, entityId: Int, data: MetadataBuilder.() -> Unit)

Sends a raw metadata update for an entity to the player.

Link copied to clipboard
abstract fun setBowAnimation(player: Player, entityId: Int)

Sends a bow/crossbow charging animation packet for an entity to the player.

Link copied to clipboard
abstract fun setEatingAnimation(player: Player, entityId: Int)

Sends an eating animation packet for an entity to the player.

Link copied to clipboard
abstract fun setEntityMotion(player: Player, entityId: Int, velocity: Vector)

Sets the velocity/motion of an entity for the player via a packet.

Link copied to clipboard
abstract fun setGuardPose(player: Player, entityId: Int)

Sends a shield/sword guard pose packet for an entity to the player.

Link copied to clipboard
abstract fun setSleepAnimation(player: Player, entityId: Int, location: Location)

Sends a sleep animation packet for an entity at the given location to the player.

Link copied to clipboard
abstract fun showEntity(player: Player, entityId: Int)

Shows a previously hidden entity to the player.