PointClickEngine::Navigation::PathfindingDebugRenderer
Inherits Reference < Object
Debug visualization for pathfinding and navigation
The PathfindingDebugRenderer provides visual debugging tools for pathfinding algorithms, navigation grids, and character movement. It should only be used during development and debugging.
Constructors
Instance methods
blocked_color
Sourceblocked_color=(blocked_color : RL::Color)
Sourcedraw_algorithm_state(visited_nodes : Set(Tuple(Int32, Int32)), open_nodes : Set(Tuple(Int32, Int32)), alpha : UInt8 = 80_u8)
Draws pathfinding algorithm state (visited and open nodes)
draw_character_info(character_pos : RL::Vector2, target_pos : RL::Vector2 | Nil = nil, character_radius : Float32 = 10.0_f32)
Draws character position and target
draw_grid(color_walkable : RL::Color = @walkable_color, color_blocked : RL::Color = @blocked_color, alpha : UInt8 = @grid_alpha)
Draws the navigation grid
draw_grid_coordinates(font_size : Int32 = 8, spacing : Int32 = 4)
Draws grid coordinates for debugging
draw_grid_outlined(color_walkable : RL::Color = @walkable_color, color_blocked : RL::Color = @blocked_color, outline_color : RL::Color = RL::BLACK, alpha : UInt8 = @grid_alpha)
Draws the navigation grid with outline
draw_grid_stats(x : Int32 = 10, y : Int32 = 10, font_size : Int32 = 16)
Draws navigation grid statistics
draw_node_costs(nodes : Hash(Tuple(Int32, Int32), Tuple(Float32, Float32, Float32)), font_size : Int32 = 10)
Draws node costs for debugging
draw_path(path : Array(RL::Vector2), color : RL::Color = @path_color, thickness : Float32 = @path_thickness)
Draws a path with waypoints
draw_path_directions(path : Array(RL::Vector2), arrow_size : Float32 = 5.0_f32, color : RL::Color = RL::GREEN)
Draws directional arrows along path
draw_path_simple(path : Array(RL::Vector2), color : RL::Color = @path_color, thickness : Float32 = @path_thickness)
Draws a simple path without waypoints
draw_performance_info(x : Int32, y : Int32, search_time : Float64, nodes_explored : Int32, path_length : Float32, font_size : Int32 = 16)
Draws pathfinding performance info
enabled
Sourceenabled=(enabled : Bool)
Sourceend_color
Sourceend_color=(end_color : RL::Color)
Sourcehighlight_cells(cells : Array(Tuple(Int32, Int32)), color : RL::Color = RL::MAGENTA, alpha : UInt8 = 150_u8)
Highlights specific grid cells
open_color
Sourceopen_color=(open_color : RL::Color)
Sourcepath_color
Sourcepath_color=(path_color : RL::Color)
Sourcepath_thickness
Sourcepath_thickness=(path_thickness : Float32)
Sourcestart_color
Sourcestart_color=(start_color : RL::Color)
Sourcevisited_color
Sourcevisited_color=(visited_color : RL::Color)
Sourcewaypoint_radius
Sourcewaypoint_radius=(waypoint_radius : Float32)
Source