RaweTrip
  • Welcome
  • Official Discord
  • Useful information
    • πŸ”ŒFor beginners
    • β™ŸοΈCommon knowledge
    • πŸ“šExamples
      • βš™οΈTab system
      • βš™οΈUI Interaction
      • βš™οΈClantag
      • βš™οΈWireframe smoke
  • documentation
    • ⛓️Common
      • πŸ“žCallbacks list
    • βš™οΈVariables
      • πŸ‘€esp
      • πŸ“œplist
      • πŸ”«weapon
      • ⚑vector
      • 🎨color
      • πŸŽ“cheat
      • πŸ’»ui
      • πŸ™οΈrender
      • πŸšΆβ€β™‚οΈentity
      • 🌎globalvars
      • πŸ› οΈengine
      • πŸ”©utils
      • πŸ–₯️console
      • πŸ”‘base64
      • πŸ“ bit
      • πŸ—ƒοΈfile
      • πŸ“Άhttp
      • βœ‰οΈchat
      • 〽️animate
      • 🧱materials
      • πŸ”§steam
      • ✈️trace
      • πŸ”—interfaces
        • πŸ’‘ieffects
        • 🧬precache
        • πŸ’³model_info
    • πŸ”’Enumerations
      • 🎞️enum_frames
Powered by GitBook
On this page
  • Example available!
  • Elements:
  • add_checkbox
  • add_combobox
  • add_sliderint
  • add_sliderfloat
  • add_button
  • add_colorpicker
  • add_label
  • add_hotkey
  • add_input
  • get_keybind_state
  • get_keybind_mode
  • set_keybind_state
  • Functions:
  • :get
  • :set
  • :set_visible
  • :set_callback
  • :set_group
  • Combobox additive functions:
  • :set_items
  • :get_items
  • Hotkey additive functions:
  • :get_mode
  • Find menu items:
  1. documentation
  2. Variables

ui

PreviouscheatNextrender

Last updated 2 years ago

Example available!

Elements:

add_checkbox

ui.add_checkbox(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

add_combobox

ui.add_combobox(name: string, items: {, ...}): MenuItem

Name
Type
Description

name

string

Item name

items

string

Items

Creates and returns a menu item object, or throws an error on failure.

add_sliderint

ui.add_sliderint(name: string, min: number, max: number): MenuItem

Name
Type
Description

name

string

Item name

min

number

Minimum value

max

number

Maximum value

Creates and returns a menu item object, or throws an error on failure.

add_sliderfloat

ui.add_sliderfloat(name: string, min: number, max: number): MenuItem

Name
Type
Description

name

string

Item name

min

number

Minimum value

max

number

Maximum value

Creates and returns a menu item object, or throws an error on failure.

add_button

ui.add_button(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

add_colorpicker

ui.add_colorpicker(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

add_label

ui.add_label(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

add_hotkey

ui.add_hotkey(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

add_input

ui.add_input(name: string): MenuItem

Name
Type
Description

name

string

Item name

Creates and returns a menu item object, or throws an error on failure.

get_keybind_state

ui.get_keybind_state(name: string)

Name
Type
Description

name

string

Item name

Returns true, if keybind is active.

get_keybind_mode

ui.get_keybind_mode(name: string)

Name
Type
Description

name

string

Item name

Returns the keybind mode.

set_keybind_state

ui.set_keybind_state(name: string, var: boolean)

Name
Type
Description

name

string

Item name

var

boolean

Item var

Sets the keybind boolean value.

Functions:

:get

<element>:get(): any

Returns the value of the menu item.

:set

<element>:set(value: any)

Name
Type
Description

value

any

The value to which the menu item will be set

Sets the value of the menu item.

:set_visible

<element>:set_visible(state: boolean)

Name
Type
Description

state

boolean

New visibility state

Shows or hides the menu item depending on the value of state.

:set_callback

Works only in callbacks.

<element>:set_callback(callback: function)

Name
Type
Description

callback

function

Function that will be called when the menu item is interacted with

local checkbox = ui.add_checkbox("Checkbox")

cheat.push_callback("on_paint", function()
    checkbox:set_callback(function()
        cheat.notify("Callback")
    end)
end)

Sets the callback to the specified menu item.

:set_group

<element>:set_group(group: number)

Name
Type
Description

group

number

1 - Left group 2 - Right group

Sets the group to the specified menu item.

Combobox additive functions:

:set_items

<element>:set_items(items: {, ...})

Name
Type
Description

items

string

Table with string values

Sets a table with items. ui.add_combobox menu item objects only.

:get_items

<element>:get_items(): table

Returns the table of items. ui.add_combobox menu item objects only.

Hotkey additive functions:

:get_mode

<element>:get_mode(): number

Returns the current keybind mode. ui.add_hotkey menu item objects only.

Find menu items:

ui.find_menu_int(item_name: string): MenuItem

Name
Type
Description

item_name

string

-

ui.find_menu_float(item_name: string): MenuItem

Name
Type
Description

item_name

string

-

ui.find_menu_bool(item_name: string): MenuItem

Name
Type
Description

item_name

string

-

ui.find_menu_color(item_name: string): MenuItem

Name
Type
Description

item_name

string

-

--> Example
local fake_lag_limit = ui.find_menu_int("Antiaim.fake_lag_limit")

fake_lag_limit:set(10)

cheat.notify(fake_lag_limit:get())

Returns the MenuItem object that corresponds to the specified name.

βš™οΈ
πŸ’»
βš™οΈUI Interaction