Escoria main room handling and scene switcher
var last_scene_global_id: String
Global id of the last scene the player was before current scene
var current_scene: Node
Current scene room being displayed
var previous_scene: Node
Scene that was previously the current scene.
The Escoria context currently in wait state
var scene_transition: ESCTransitionPlayer
Reference to the scene transition node
func set_scene(p_scene: Node) -> void
Set current scene
p_scene: Scene to set
func finish_current_scene_init(p_scene: Node) -> void
Only called by the room manager in the case where it hasn’t executed a coroutine prior to calling set_scene_finish().
p_scene: The scene currently being initialized by set_scene.
func set_scene_finish() -> void
Completes the room swap and should be called by the room manager at the appropriate time.
func clear_previous_scene() -> void
Cleanup the previous scene if there was one.
func set_camera_limits(camera_limit_id: int = 0, scene: Node) -> void
Set the camera limits
camera_limits_id: The id of the room’s camera limits to set
scene: The scene to set the camera limits for. We make this optional since most times it’ll be current_scene that needs setting; however, e.g. when starting up Escoria, we might not have already set the current_scene.
func save_game(p_savegame_res: Resource) -> void
Sanity check that the game.tscn scene’s root node script MUST implement the following methods. If they do not exist, stop immediately. Implement them, even if empty
signal room_ready(): Signal sent when the room is loaded and ready.