esp
Add your own text, flags and bars to the player ESP. They show under LUA in the ESP element list.
Functions
group:new_text
group:new_text(name [, preview], fn) -> element| Name | Type | Description |
|---|---|---|
| name | string | Chip label and save key. |
| previewoptional | string | Sample on chip hover. Default name. |
| fn | function(player) | Returns text, or nil to hide. |
Text on a side of the box; starts at the bottom.
- fn may return a colour second ({r,g,b,a} or draw.color()); it beats the menu colour.
- fn runs once per drawn player per frame, under the on_paint budget.
group:new_flag
group:new_flag(name [, preview], fn) -> element| Name | Type | Description |
|---|---|---|
| name | string | Chip label and save key. |
| previewoptional | string | Sample on chip hover. Default name. |
| fn | function(player) | Returns text, or nil to hide. |
Like new_text, but starts on the right with the built-in flags.
group:new_bar
group:new_bar(name, fn) -> element| Name | Type | Description |
|---|---|---|
| name | string | Chip label and save key. |
| fn | function(player) | Returns 0 to 1, or nil to hide. |
Bar along a side of the box; starts on the left.
Bars stack outside health and armour.
element:get
element:get() -> booleanWhether it's switched on.
element:set
element:set(on)| Name | Type |
|---|---|
| on | boolean |
Switches it on or off.
element:name
element:name() -> stringIts name.
element:position
element:position() -> string"left", "right", "top" or "bottom".
element:set_position
element:set_position(side)| Name | Type | Description |
|---|---|---|
| side | string | left, right, top or bottom. |
Moves it to a side.
element:color
element:color() -> tableMenu colour as {r, g, b, a}.
element:set_color
element:set_color(color)| Name | Type | Description |
|---|---|---|
| color | table | integer | {r,g,b,a} or draw.color() |
Sets the menu colour.
element:create
element:create() -> ui.CardSettings card in the element's right-click menu; same builders as tab:card().
element:remove
element:remove()Takes it out of the ESP and the menu.
element:is_valid
element:is_valid() -> booleanFalse after remove or a script reload.
Elements go away when their script reloads, is disabled or deleted.
Fields
Player groups
| Name | Type | Description |
|---|---|---|
| esp.enemy | group | Enemies, hostile NPCs included. |
| esp.team | group | Teammates. |
| esp.local_player | group | You, in thirdperson. Same as esp["local"]. |
| esp.npc | group | Friendly NPCs. |