Space Station 13 - Modules - TypesVar Details - Proc Details

tgui_say

The tgui say modal. This initializes an input window which hides until the user presses one of the speech hotkeys. Once something is entered, it will delegate the speech to the proper channel.

Vars

clientThe user who opened the window
windowThe modal window
window_openBoolean for whether the tgui_say was opened by the user.

Procs

NewCreates the new input window to exist in the background.
closeCloses the window serverside. Closes any open chat bubbles regardless of preference.
delegate_speechDelegates the speech to the proper channel.
handle_entryHandles text entry and forced speech.
initializeAfter a brief period, injects the scripts into the window to listen for open commands.
loadEnsures nothing funny is going on window load. Minimizes the window, sets max length, closes all typing and thinking indicators. This is triggered as soon as the window sends the "ready" message.
on_messageThe equivalent of ui_act, this waits on messages from the window and delegates actions.
openSets the window as "opened" server side, though it is already visible to the user. We do this to set local vars & start typing (if enabled and in an IC channel).
start_thinkingSets the mob as "thinking" - with indicator
start_typingHandles the user typing. After a brief period of inactivity, signals the client mob to revert to the "thinking" icon.
stop_thinkingSpecial exemptions Removes typing/thinking indicators and flags the mob as not thinking
stop_typingCallback to remove the typing indicator after a brief period of inactivity. If the user was typing IC, the thinking indicator is shown.

Var Details

client

The user who opened the window

window

The modal window

window_open

Boolean for whether the tgui_say was opened by the user.

Proc Details

New

Creates the new input window to exist in the background.

close

Closes the window serverside. Closes any open chat bubbles regardless of preference.

delegate_speech

Delegates the speech to the proper channel.

Arguments: entry - the text to broadcast channel - the channel to broadcast in Returns: boolean - on success or failure

handle_entry

Handles text entry and forced speech.

Arguments: payload - a string list containing entry & channel Returns: boolean - success or failure

initialize

After a brief period, injects the scripts into the window to listen for open commands.

load

Ensures nothing funny is going on window load. Minimizes the window, sets max length, closes all typing and thinking indicators. This is triggered as soon as the window sends the "ready" message.

on_message

The equivalent of ui_act, this waits on messages from the window and delegates actions.

open

Sets the window as "opened" server side, though it is already visible to the user. We do this to set local vars & start typing (if enabled and in an IC channel).

Arguments: payload - A list containing the channel the window was opened in.

start_thinking

Sets the mob as "thinking" - with indicator

start_typing

Handles the user typing. After a brief period of inactivity, signals the client mob to revert to the "thinking" icon.

stop_thinking

Special exemptions Removes typing/thinking indicators and flags the mob as not thinking

stop_typing

Callback to remove the typing indicator after a brief period of inactivity. If the user was typing IC, the thinking indicator is shown.