diff options
| author | radiohotline <radoihotline@disroot.rg> | 2026-08-25 16:33:56 +0300 |
|---|---|---|
| committer | radiohotline <radoihotline@disroot.rg> | 2026-08-25 16:33:56 +0300 |
| commit | a89e744ed0e8c759caf041a580112365bbfe4303 (patch) | |
| tree | dd61e320904176995727e86a857d00c90d4933ba /addons/escoria-core/game/esc_autoload.gd | |
| parent | 6d53d8cac78250dc888aa49d5f9d4175c6652feb (diff) | |
Diffstat (limited to 'addons/escoria-core/game/esc_autoload.gd')
| -rw-r--r-- | addons/escoria-core/game/esc_autoload.gd | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/addons/escoria-core/game/esc_autoload.gd b/addons/escoria-core/game/esc_autoload.gd index 72ef6f8..a36b9da 100644 --- a/addons/escoria-core/game/esc_autoload.gd +++ b/addons/escoria-core/game/esc_autoload.gd @@ -2,6 +2,14 @@ extends Node ## This is Escoria's singleton script. ## It holds accessors to some utils, such as Escoria's logger. +## Signal sent when Escoria starts a new game[br] +## [br] +## #### Parameters[br] +## [br] +## None. +## [br] +signal new_game_started + ## Signal sent when Escoria is paused[br] ## [br] ## #### Parameters[br] @@ -24,7 +32,7 @@ signal resumed ## * DIALOG: Game is playing a dialog ## * WAIT: Game is waiting ## * LOADING: Game is currently loading -enum GAME_STATE { +enum GameState { DEFAULT, DIALOG, WAIT, @@ -149,8 +157,8 @@ var creating_new_game: bool = false ProjectSettings.get_setting("display/window/size/viewport_width"), ProjectSettings.get_setting("display/window/size/viewport_height")) -## Current state of Escoria (GAME_STATE enum) -@onready var current_state = GAME_STATE.DEFAULT +## Current state of Escoria (GameState enum) +@onready var current_state = GameState.DEFAULT ## Ready function. Instantiates the main scene if running a room directly.[br] ## [br] @@ -196,8 +204,7 @@ func get_escoria(): # We check if we run the full game or a room scene directly if get_tree().current_scene is ESCMain: return get_node("/root/main_scene").escoria_node - else: - return get_node("main_scene").escoria_node + return get_node("main_scene").escoria_node ## Pauses or unpause the game[br] |
