Lorekeeper Entity
The Lorekeeper NPC entity that conducts interviews and sells lore books.
Extends WanderingTrader to reuse the trading UI. Offers weekly news books, history compilations, archived player submissions, and accepts written book submissions.
Implements PolymerEntity so the entity appears as a player with a custom skin to ALL clients (vanilla, modded, Bedrock via Geyser) without needing the mod installed or a resource pack. The skin data is Mojang-signed via LorekeeperSkin.
Constructors
Types
Properties
UUID of the player this Lorekeeper is following, or null if not following anyone.
Functions
Awards the Lorekeeper dismiss advancement to player.
Clears the current follow target and restores default roaming speed.
Enables the HQ master behavior profile (slow wander, book-and-quill, no panic sprinting).
Returns EntityType.PLAYER so vanilla clients render this entity as a player with the custom skin provided via onBeforeSpawnPacket.
Modifies the data tracker entries sent to clients to match what a player entity expects.
Returns the next skin index after the currently active one.
Sends a ClientboundPlayerInfoUpdatePacket before the entity spawn packet so the client downloads the Lorekeeper's skin texture from Mojang's servers. Without this, the client would render a Steve/Alex default skin.
Sets the player for this Lorekeeper to follow.
Sets a specific skin index, wrapping out-of-range values safely.