Open Book
Play 0x3A, server → client.
play · 0x3A · clientbound (server → client)
Tells the client to open the book screen for the written book held in hand (main hand or off hand). The server sends it when the player uses a written book. The client reads the book contents from the item stack in that hand.
Sent by the server, read by the client. Listen for it with client.on("OpenBook", (data) => …) on the receiving side.
Fields
| Field | Type | Notes |
|---|---|---|
hand |
VarInt |
Send it
await client.sendPacket("OpenBook", {
hand: /* VarInt */,
});
Field aliases listed under Notes are accepted as alternative keys when writing.
Source: src/Core/Versions/776/Packets/play/clientbound/OpenBook.ts