55 lines
954 B
GDScript
55 lines
954 B
GDScript
extends Node
|
|
|
|
# globals, for the game
|
|
var reading_speed = 1.0
|
|
|
|
var game_started = false setget _on_game_started_set
|
|
|
|
var current_registry
|
|
|
|
# music related
|
|
onready var music_player = get_node("music_player")
|
|
onready var sfx_player = get_node("sfx_player")
|
|
|
|
signal on_music_volume_changed(new_value)
|
|
signal on_sfx_volume_changed(new_value)
|
|
signal on_reading_speed_changed(new_value)
|
|
|
|
signal on_settings_enter()
|
|
signal on_settings_exit()
|
|
|
|
const Themes = {}
|
|
|
|
# voices for characters
|
|
const brain_voice = null
|
|
const arborator_voice = null
|
|
|
|
const Characters = {
|
|
BRAIN = {
|
|
name = "~brain~",
|
|
voice = brain_voice,
|
|
talking_speed = 1.0,
|
|
},
|
|
ARBORATOR = {
|
|
name = "arborator",
|
|
voice = arborator_voice,
|
|
talking_speed = 1.0,
|
|
}
|
|
}
|
|
|
|
func _register_functions():
|
|
pass
|
|
|
|
func _on_game_started_set(v):
|
|
if v and not game_started:
|
|
_on_game_start()
|
|
game_started = v
|
|
|
|
func _on_game_start():
|
|
|
|
# all game state here
|
|
current_registry = {}
|
|
|
|
|
|
func _ready():
|
|
pass |