WAD::TextureX
Inherits WritingAdditions::TextureX < Reference < Object
Defines how wall patches from the WAD file should combine to form wall textures.
Constructors
parse(filename : String | Path) : TextureX
Parses a texture map file given the filename
Opens a texture map file and parses it:
my_texturemap = WAD::TextureX.parse("Path/To/TextureMap")
parse(io : IO) : TextureX
Parses a texture map file given the io
Opens a texture map io and parses it:
File.open("Path/To/TextureMap") do |file|
my_texturemap = WAD::TextureX.parse(file)
end
Class methods
is_texturex?(name : String)
Checks to see if name is "TEXTUREx"
Returns true if the name is a texture map:
texturemap_name = "TEXTURE1"
if WAD::TextureX.is_texturex?(texturemap_name)
puts "Is a Texture Map"
else
puts "Is not a Texture Map"
end
Instance methods
clone
Returns a copy of self with all instance variables cloned.
mtextures
mtextures=(mtextures : Array(TextureMap))
numtextures
numtextures=(numtextures : Int32)
offsets
offsets=(offsets : Array(Int32))