struct WAD::Map::Node
- WAD::Map::Node
- Struct
- Value
- Object
Overview
Structure of a node.
Defined in:
wa-cr/wad/wad-data/map.crConstructors
Class Method Summary
-
.parse(io : IO, lump_size : Int) : Array(Node)
Parses a nodes list given the io and the size
-
.parse(filename : String | Path) : Array(Node)
Parses a nodes list given the filename
Instance Method Summary
-
#clone
Returns a copy of
self
with all instance variables cloned. - #initialize
-
#left_bound_box : Array(Int16)
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
-
#left_bound_box=(left_bound_box : Array(Int16))
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
- #left_child : Int16
- #left_child=(left_child : Int16)
-
#right_bound_box : Array(Int16)
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
-
#right_bound_box=(right_bound_box : Array(Int16))
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
- #right_child : Int16
- #right_child=(right_child : Int16)
-
#x_change_to_end : Int16
Change in x from start to end of partition line.
-
#x_change_to_end=(x_change_to_end : Int16)
Change in x from start to end of partition line.
-
#x_coord : Int16
X coordinate of partition line start.
-
#x_coord=(x_coord : Int16)
X coordinate of partition line start.
-
#y_change_to_end : Int16
Change in y from start to end of partition line.
-
#y_change_to_end=(y_change_to_end : Int16)
Change in y from start to end of partition line.
-
#y_coord : Int16
Y coordinate of partition line start.
-
#y_coord=(y_coord : Int16)
Y coordinate of partition line start.
Constructor Detail
Class Method Detail
Parses a nodes list given the io and the size
Opens a nodes lump and parses it:
File.open("Path/To/Node") do |file|
my_nodes = WAD::Map::Node.parse(file, file.size)
end
Parses a nodes list given the filename
Opens a nodes lump and parses it:
my_nodes = WAD::Map::Node.parse("Path/To/Node")
Instance Method Detail
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).
A bounding box consists of four short values (top, bottom, left and right) giving the upper and lower bounds of the y coordinate and the lower and upper bounds of the x coordinate (in that order).