Skip to main content

Module control

Module control 

Source
Expand description

This client’s player doing what a player does — its own keys held, its clicks — for tours, cut scenes, bots: the host’s actions (nothing on a dedicated server, nor without a player).

Structs§

Attack
Attacks entity entity (its uuid), or (None) what the crosshair is on; whether something was hit.
Chat
Sends text to the chat — a command when it starts with /.
Click
Clicks slot of the open container (button as the game’s).
Drive
Holds the movement keys each tick till release: forward -1 (back) to 1, strafe -1 (right) to 1 (left); use_item raises a shield, draws a bow, eats.
Look
Turns the player to yaw, pitch (degrees).
Mine
Keeps breaking the block at pos from face (call each tick); whether it’s still there.
Place
Places the held block against the block at pos, on face; whether the game took it.
Release
Gives the movement keys back to the player.
SelectSlot
Selects hotbar slot slot (0–8).
StopMining
Stops breaking a block.
UseItem
Uses the held item, the main hand’s or the off hand’s.

Functions§

attack
Attacks entity entity (its uuid), or (None) what the crosshair is on; whether something was hit.
chat
Sends text to the chat — a command when it starts with /.
click
Clicks slot of the open container (button as the game’s).
drive
Holds the movement keys each tick till release: forward -1 (back) to 1, strafe -1 (right) to 1 (left); use_item raises a shield, draws a bow, eats.
look
Turns the player to yaw, pitch (degrees).
mine
Keeps breaking the block at pos from face (call each tick); whether it’s still there.
place
Places the held block against the block at pos, on face; whether the game took it.
release
Gives the movement keys back to the player.
select_slot
Selects hotbar slot slot (0–8).
stop_mining
Stops breaking a block.
use_item
Uses the held item, the main hand’s or the off hand’s.