Game::TileMap::Tile - Map tile representation
This is a simple struct-like object that holds data about one tile on a map.
Horizontal position of this tile on a map.
Vertical position of this tile on a map.
Contents of the tile. By default, same as "type", but you can change it with "set_contents".
Is this tile a wall?
Is this tile a void?
Type of the tile, as defined in the legend (as $object)
$object
Moose-flavored constructor. See "Attributes" for a list of possible arguments.
In addition, the constructor requires the argument legend - map legend, but it is only required during building of the object (not stored).
legend
Sets new "contents" for this tile. Useful if you want to specify this tile without changing the legend (which may be used across many maps). You can set contents to be anything, since "type" is what is used to perform any checks.
To install Game::TileMap, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Game::TileMap
CPAN shell
perl -MCPAN -e shell install Game::TileMap
For more information on module installation, please visit the detailed CPAN module installation guide.