HApex 3.0 Lua · Scripting Documentation
Extend the menu · ESP · network · events · drawing with Lua. Every API description maps to a real callable function or field, and the examples are copy-paste ready.
Start with the Guide to get a first script running, then jump into a module below; full field tables are split per-module in the sidebar API section.
Modules
| Module | What it does |
|---|---|
Menu & Controls gui | Tab / Window / Groupbox containers; checkbox · slider · combobox · multi_dropdown · color_edit · input_text · button · keybind_control · live_table · tips |
ESP Elements esp | One-line esp.add for custom text / progress bars / mixed / freedraw; 4 scenarios each with independent colors, slot-based layout |
Events event | Render frame · menu toggled · player lifecycle (knocked/revived/died/respawned) · custom events; subscriptions auto-cleaned on script unload |
Network net | HTTP GET / POST fully async; WebSocket with 4 callbacks (open · message · error · close) |
Live Data game | Local player · enemies · loot · projectiles · aim · ring · map — read-only snapshots |
Drawing draw | Lines · rects · circles (incl. clockwise arcs) · triangles · quads · polylines · outlined text · images (incl. rotated) · gradients · color ops (HSV/lerp/mod_a/darken/lighten) · clip stack |
Math & Animation math | Vec2 / Vec3 with full operators · projection · 6 easing curves |
File & Assets file | Sandboxed file I/O · directory enumeration · PNG / SVG / procedural images |
JSON Tools json | encode / decode both ways; pairs naturally with HTTP / file persistence |
DMA Memory mem | get_module_base · find_pattern · single reads / scatter batch (u8..u64 / float / vec / bytes / string); read-only, no write |
Module overview
══ Core 9 ════════════════════════════════════════════════════════════════
event subscriptions
gui menu + config
esp ESP elements
net HTTP / WebSocket
game live data (read-only)
draw on-screen drawing
math vectors + projection + animation
file files + images
input key state + display
══ Utility 8 ═════════════════════════════════════════════════════════════
log diagnostic logging
notify user toasts
script load / unload
time now · delta · game · frame_count
config plan switching
json encode · decode
utils base64 encode/decode
mem DMA reads · pattern scan · scatter batchExample scripts
The 8 scripts below ship in the scripts/ directory and can be referenced or modified directly. Full source: Getting Started.
| Script | Function |
|---|---|
keybind_hint_pack.lua | Dynamic text / color hints attached to keybind controls |
low_health_alert.lua | Teammate down · self / teammate low-HP one-shot toast |
tactical_theme.lua | One-click ESP theme switch, 4 scenarios each colored |
perf_hud.lua | Floating window showing FPS · frame time · entity count |
loadout_presets.lua | Switch between multiple config presets, floater shows current |
loot_inspector.lua | Browse current loot snapshot · name · distance · tier |
remote_config_push.lua | WebSocket receives path=value commands to hot-update menu |
damage_logger.lua | Damage log to local CSV + HTTP archive |