Skip to main content

ui.new_button

Throws an error on failure. The return value should not be used with ui.set or ui.get.

ui.new_button(tab: string, container: string, name: string, callback): number

Arguments

NameDescriptionType
tabThe name of the tab: RAGE, AA, LEGIT, VISUALS, MISC, SKINS, PLAYERS, LUA.string
containerThe name of the existing container to which this checkbox will be added.string
nameThe name of the button.string
callbackThe lua function that will be called when the button is pressed.function

Returns menu item: number