This contains the source code documentation of the class subsystem_Choices
.
subsystem_Choices
Inherits: DialogicSubsystem
Subsystem that manages showing and activating of choices.
Properties
Name | Type | Default |
---|---|---|
autofocus_first_choice | bool | true |
block_delay | float | 0.2 |
default_false_behaviour | int | 0 |
hotkey_behaviour | int | 0 |
last_question_info | Dictionary | |
reveal_by_input | bool | false |
reveal_delay | float | 0.0 |
Methods
Returns | Method |
---|---|
void | clear_game_state ( clear_flag : int = 0 ) |
Array | get_current_choice_indexes ( ) |
void | hide_all_choices ( ) |
bool | is_question ( index : int ) |
void | show_choice ( button_index : int, text : String, enabled : bool, event_index : int ) |
void | show_current_choices ( instant : bool = true ) |
Constants
No description available.
No description available.
No description available.
No description available.
Signals
signal choice_selected ( info
: Dictionary )
Emitted when a choice button was pressed. Info includes the keys 'button_index', 'text', 'event_index'.
signal choices_shown ( info
: Dictionary )
Emitted when a set of choices is reached and shown. Info includes the keys 'choices' (an array of dictionaries with infos on all the choices).
Property Descriptions
var autofocus_first_choice = true
If true, the first (top-most) choice will be focused
The delay between the choices becoming visible and being clickable. Can prevent accidental selection.
var default_false_behaviour = 0
The behaviour of choices with a false condition and else_action set to DEFAULT.
Will add some hotkeys to the choices if different then HotkeyBehaviour.NONE.
Contains information on the latest question.
If true the player has to click to reveal choices when they are reached
The delay between the text finishing revealing and the choices appearing
Method Descriptions
func clear_game_state ( clear_flag
: int = 0
) ⇒ void
No description available.
func get_current_choice_indexes ( ) ⇒ Array
No description available.
func hide_all_choices ( ) ⇒ void
Hides all choice buttons.
func is_question ( index
: int ) ⇒ bool
No description available.
func show_choice ( button_index
: int, text
: String, enabled
: bool, event_index
: int ) ⇒ void
Adds a button with the given text that leads to the given event.
func show_current_choices ( instant
: bool = true
) ⇒ void
Lists all current choices and shows buttons.