class

PointClickEngine::Scenes::Scene

Inherits YAML::Serializable < Reference < Object

Refactored Scene class using component architecture

Constructors

new(ctx : YAML::ParseContext, node : YAML::Nodes::Node)
Source
new(name : String)
Source
new(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)
Source

Instance methods

actions_path
Source
actions_path=(actions_path : String | Nil)
Source
add_character(character : Characters::Character)

Character management

Source
add_hotspot(hotspot : Hotspot)

Hotspot management (delegates to HotspotManager)

Source
add_object(object : Core::GameObject)

Object management

Source
after_yaml_deserialize(ctx : YAML::ParseContext)

YAML deserialization support

Source
background

Legacy compatibility - will be removed

Source
background=(background : RL::Texture2D | Nil)

Legacy compatibility - will be removed

Source
background_path

Serialization support

Source
background_path=(background_path : String | Nil)

Serialization support

Source
background_renderer
Source
background_renderer=(background_renderer : BackgroundRenderer | Nil)
Source
background_scaling_mode
Source
background_scaling_mode=(value : String)
Source
base_dir

Base directory for resolving relative paths (set by SceneLoader)

Source
base_dir=(base_dir : String)

Base directory for resolving relative paths (set by SceneLoader)

Source
characters
Source
characters=(characters : Array(Characters::Character))
Source
default_transition_duration
Source
default_transition_duration=(default_transition_duration : Float32)
Source
draw(camera : Graphics::Camera | Nil = nil)

Render scene

Source
draw_script_overlays

Draw script runner overlays (text, custom visuals from actions)

Source
enable_camera_scrolling
Source
enable_camera_scrolling=(enable_camera_scrolling : Bool)
Source
enable_pathfinding
Source
enable_pathfinding=(enable_pathfinding : Bool)
Source
enter

Scene lifecycle

Source
exit
Source
find_path(start_x : Float32, start_y : Float32, end_x : Float32, end_y : Float32) : Array(Raylib::Vector2) | Nil

Pathfinding (delegates to NavigationManager)

Source
get_character(name : String) : Characters::Character | Nil
Source
get_character_at(point : RL::Vector2) : Characters::Character | Nil
Source
get_character_scale(y_position : Float32) : Float32
Source
get_hotspot_at(point : RL::Vector2) : Hotspot | Nil
Source
highlight_hotspots
Source
highlight_hotspots=(highlight_hotspots : Bool)
Source
hotspot_manager
Source
hotspot_manager=(hotspot_manager : HotspotManager | Nil)
Source
hotspots
Source
hotspots=(hotspots : Array(Hotspot))
Source
is_area_walkable?(center : RL::Vector2, size : RL::Vector2, scale : Float32 = 1.0) : Bool
Source
is_walkable?(point : RL::Vector2) : Bool

Walkability checks

Source
load_actions

Load and play scene's actions if actions_path is set

Source
load_background(path : String, scale : Float32 = 1.0)

Background management (delegates to BackgroundRenderer)

Source
load_background(path : String, original_path : String, scale : Float32 = 1.0)
Source
load_script(engine : Core::Engine)

Script loading (Lua scripts)

Source
logical_height
Source
logical_height=(value : Int32)
Source
logical_width
Source
logical_width=(value : Int32)
Source
name

Core properties

Source
name=(name : String)

Core properties

Source
objects

Scene state

Source
objects=(objects : Array(Core::GameObject))

Scene state

Source
on_enter

Callbacks

Source
on_enter=(on_enter : Proc(Nil) | Nil)

Callbacks

Source
on_exit
Source
on_exit=(on_exit : Proc(Nil) | Nil)
Source
pathfinder
Source
pathfinder=(pathfinder : Navigation::Pathfinding | Nil)
Source
player
Source
player=(player : Characters::Character | Nil)
Source
player_name_for_serialization
Source
player_name_for_serialization=(player_name_for_serialization : String | Nil)
Source
remove_hotspot(name : String) : Bool
Source
remove_hotspot(hotspot : Hotspot) : Bool
Source
run_script(runner : Actions::ActionRunner)

Run an action sequence from an ActionRunner

Source
run_script_file(path : String)

Run actions from YAML file

Source
scale
Source
scale=(scale : Float32)
Source
scene_effects
Source
scene_effects=(scene_effects : Array(Graphics::Effects::SceneEffects::BaseSceneEffect))
Source
script_path
Source
script_path=(script_path : String | Nil)
Source
script_runner

Script runner for action sequences

Source
script_runner=(script_runner : Actions::ActionRunner | Nil)

Script runner for action sequences

Source
script_running?

Check if an action sequence is running

Source
set_player(player : Characters::Character)
Source
setup_navigation(character_radius : Float32 = 56.0_f32)

Navigation setup (delegates to NavigationManager)

Source
skip_script

Skip current action sequence (if skippable)

Source
stop_script

Stop current action sequence

Source
toggle_hotspot_highlight

Toggle hotspot highlighting

Source
update(dt : Float32)

Update scene

Source
walkable_area
Source
walkable_area=(walkable_area : WalkableArea | Nil)
Source