User Interface#
Provides functionality for drawing and interacting with in-game user interface elements: messages, panels, buttons, text and input fields.
Example#
The following example shows a message at the top of the screen for 10 seconds:
import { connect } from "@krpc-org/krpc";
const conn = await connect({ name: "User Interface Example" });
await conn.ui.message("Hello, World!", { duration: 10 });