class Tile::Map

Defined in:

tile/map.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(tile_size : SF::Vector2(Int32), width, map) #

[View source]

Instance Method Detail

def assign_tile_at(pos : SF::Vector2(Int32), index) #

[View source]
def height : UInt32 #

[View source]
def map : Array(UInt32) #

Tile map. Should be width * height in size.


[View source]
def next_tile_at(pos : SF::Vector2(Int32)) #

[View source]
def prev_tile_at(pos : SF::Vector2(Int32)) #

[View source]
def tile_at(pos : SF::Vector2(Int32)) #

[View source]
def tile_size : SF::Vector2(Int32) #

Individual tile size


[View source]
def width : UInt32 #

Width and height, in tiles.


[View source]