Skip to content

API function index

Status: Implemented (API 1.24). Generated from client/clight/idl/clight_api.json by tools/docs/gen_api_reference.py; do not edit by hand.

API 1.24 has 613 functions, 59 events, 113 structs and 71 enums. Each table below is one IDL module. Anything not listed in these tables does not exist yet; the hand-written pages mark such parts as Planned.

Page Functions
Core (core) 12
Mod (mod) 11
Events (functions) (event) 7
Registries (registry) 24
Levels (level) 41
Entities and players (entity) 139
Item stacks (stack) 12
Text (text) 16
Commands (cmd) 21
Networking (net) 21
Scheduler (sched) 5
Keybinds (keybind) 4
Config (config) 16
GUI drawing (gui) 32
HUD (hud) 9
Screens and widgets (screen) 32
RmlUi documents (rml) 16
Container menus (menu) 7
Sound and music (sound) 32
Mixins (mixin) 11
Event list 59
Types, enums and constants
Audio and effects (audio) 21
Voice chat (voice) 5
Models (model) 11
Rendering (render) 22
Camera (camera) 6
AI and navigation (ai) 16
Files (fs) 13
HTTP (http) 5
UI kit and theme tokens (ui) 25
Components (view) 21

Naming

  • C: cl_<name>, every function is also a field of the cl_api_v1 table.
  • Lua: cl.<namespace>.<verb>, mirroring the C name (cl_buf_write_i32 is cl.buf.write_i32), and a method on the handle (player:give(...)). The old module spellings (cl.net.buf_write_i32) still work.
  • C++: a method on the handle class (clight::Entity::give) and a free function in the module’s namespace (clight::entity::player_give; the name without the module prefix). Functions that can fail return clight::Expected<T>.