st.showTextUI / st.hideTextUI — Text UI (Client)
Displays a key prompt UI in the corner of the screen. Multiple entries from different resources stack correctly.
lua
-- Show a text UI entry
st.showTextUI({
keyText = 'E', -- must be a valid key (see Keys table)
displayText = 'Interagér med kasse',
position = 'bottom-center', -- optional, default 'bottom-center'
hideKey = false, -- optional, hide key label
press = function() -- optional, fires on key release
-- do something
end,
}, optionalCallback)
-- Hide all text UI entries for the current resource
st.hideTextUI()Valid key values: E, F, G, H, SPACE, ENTER, TAB, ESC, F1–F10, 1–9, A–Z, arrow keys, numpad keys, mouse buttons (LMB, RMB), etc.
Text UI entries are automatically cleaned up when the resource stops.