> For the complete documentation index, see [llms.txt](https://kaizo-1.gitbook.io/kaizo-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kaizo-1.gitbook.io/kaizo-docs/lua-engine/overlay/essentials.md).

# Essentials

The important Overlay functions.

## toast.push

Popup on the overlay. Best feedback for load and toggles.

toast.push

```lua
toast.push("loaded")
toast.push("failed", false)
```

## draw\.esp\_box

Cheat-styled ESP box. Leave color out to follow menu colors.

draw\.esp\_box

```lua
draw.esp_box(100, 100, 60, 120)
```

## draw\.esp\_text

Outlined name-style label.

draw\.esp\_text

```lua
draw.esp_text(40, 80, "bot", nil, nil, true)
```

## draw\.text

Simple overlay text.

draw\.text

```lua
draw.text(32, 80, 0xFFFFFFFF, "hello")
```

## draw\.rect\_filled

Dark panel behind text.

draw\.rect\_filled

```lua
draw.rect_filled(20, 80, 240, 112, 0xCC15161A, 6)
```

## hud.register\_module

Chip on the HUD module list.

hud.register\_module

```lua
hud.register_module("MyFeature")
```

## ui.begin\_window and ui.button

Clickable UI when Insert menu is open.

ui.begin\_window ui.button

```lua
if ui.begin_window("Demo", 280, 120) then
    if ui.button("Ping") then
        toast.push("ping")
    end
end
ui.end_window()
```

## Also useful

* log.info
* draw\.line
* draw\.rect
* draw\.esp\_tracer
* draw\.esp\_chams
* draw\.esp\_trail
* ui.checkbox


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://kaizo-1.gitbook.io/kaizo-docs/lua-engine/overlay/essentials.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
