-
Notifications
You must be signed in to change notification settings - Fork 3
Usage
Wren edited this page Sep 29, 2020
·
1 revision
- Speed: Sets the speed of the text animation, in characters/second
- Acceleration: Sets the speed multiplier when the accelerate action is held. (ex 2.0 = 2x Speed)
- Message: The message to be displayed. Supports bbcode.
- Skip Action: The name of the InputMap action to bind to text skip. (skip immediately completes the typing when pressed.)
-
Accelerate Action: The name of the InputMap action to bind to text acceleration. While held, types at
Acceleration x Speed. - Voice: An Array of AudioStreams that the messagebox will randomly play whenever a character is typed. If empty, no sound will play.
- Player: A Nodepath indicating the AudioPlayer to use. If empty, no audio will be played.
- Autoscroll: Enable or disable automatic scrolling while typing when the content is larger than the messagebox.
- Use Alt Scroll: Switch between the standard and alternate methods of autoscroll. Method one scrolls only when a new line is typed, and fairly quickly. Method two scrolls at a steady rate based on how much text has been typed. No effect if autoscroll is disabled.
All of the above are accessible via code at all times. Additionally, the playing property can be used to get whether or not text is being typed, as well as to play or pause the typing by setting it to true or false.
- message_done: Fired when a message finishes typing, or when the message box is stopped or reset. No payload.
- paused: Fired when the message box is paused. The payload is how much time has passed since typing started. Please note that this is not 1:1 with the actual time passed and is altered by the various speed multipliers.
-
unpaused: Fired when the message box is unpaused. Payload is the same as
paused.
- void play(): Resumes typing if typing is paused.
- void pause(): Pauses typing.
- void stop(): Causes the typing to complete immediately.
- void reset(): Causes the typing to be reset to its initial state.