Added 'reserved' field to Map::Tile for building entities to claim when placed

This commit is contained in:
2019-11-28 18:52:57 -06:00
parent 8a5058cf9e
commit 6318d33782
7 changed files with 24 additions and 19 deletions

View File

@@ -104,7 +104,7 @@ class IMICRTS
end
class Tile
attr_accessor :position, :grid_position, :image, :visible, :entity, :type
attr_accessor :position, :grid_position, :image, :visible, :entity, :reserved, :type
def initialize(position:, image:, visible:, type:, tile_size:)
@position = position
@grid_position = position.clone
@@ -114,6 +114,7 @@ class IMICRTS
@image = image
@visible = visible
@entity = nil
@reserved = nil
@type = type
end
end