struct

WritingAdditions::Map::Thing

Inherits Struct < Value < Object

Structure of a thing.

Constructors

new

Class methods

write(file : String | Path, things : Array(::WAD::Map::Thing)) : ::WAD::Directory

Writes a list of things given an output io and the things to write and returns the written directory

Writes things in my_wad to a file:

my_wad = WAD.read("Path/To/Wad")
WAD::Map::Thing.write("Path/To/things.lmp", my_wad.maps["MyMap"].things)
write(io : IO, things : Array(::WAD::Map::Thing)) : ::WAD::Directory

Writes a list of things given an output io and the things to write and returns the written directory

Writes things in my_wad to a file:

my_wad = WAD.read("Path/To/Wad")
File.open("Path/To/things.lmp", "w+") do |file|
  WAD::Map::Thing.write(my_wad.maps["MyMap"].things)
end

Instance methods

initialize