Skip to Content

Text UI

Display persistent text UI elements on the screen, typically used for interaction prompts.

Exports

ExportParametersReturns
ShowTextUI(text, options)
HideTextUI()
IsTextUIOpen()boolean

ShowTextUI Parameters

ParameterTypeRequiredDescription
textstringYesText to display — keybind is parsed from [E] brackets

Options

FieldTypeDescription
keystring or falseKeybind letter override (e.g., 'G'), or false to hide the keybind box entirely
iconstringFontAwesome icon name or image URL
iconColorstringCustom icon color (hex or CSS color)
iconAnimationstringIcon animation: 'spin', 'beat', 'fade', 'bounce', 'shake', 'beatFade', 'spinPulse'
positionstring'right-center', 'left-center', 'top-center', 'bottom-center'
labelstringCustom label text above the main text
styletableCustom CSS styles

By default, the keybind box displays the key parsed from [KEY] brackets in the text (e.g., [E], [G]). If no brackets are found, it defaults to E. Use the key option to override this or hide it entirely.

Usage

Basic Text UI

exports['flux-ui-pack']:ShowTextUI('Press [E] to interact')

With Icon

exports['flux-ui-pack']:ShowTextUI('Press [E] to open', { icon = 'door-open', iconColor = '#e74c3c', iconAnimation = 'beat' })

Custom Position

exports['flux-ui-pack']:ShowTextUI('Press [G] to pick up', { icon = 'hand', position = 'top-center' })

Informational Display (No Keybind)

Use key = false to hide the keybind box entirely — useful for non-interactive info displays.

exports['flux-ui-pack']:ShowTextUI('Safe Zone', { key = false, label = 'INFO', position = 'top-center' })

Custom Keybind Override

Override the parsed keybind with a specific key letter.

exports['flux-ui-pack']:ShowTextUI('Pick up item', { key = 'G', icon = 'hand' })

Hide Text UI

exports['flux-ui-pack']:HideTextUI()

Check if Open

local isOpen = exports['flux-ui-pack']:IsTextUIOpen() if isOpen then print('Text UI is currently visible') end
Last updated on