Tile Set

A tile set holds a collection of tiles. The tiles can then be refered to by their tile set name and by their individual name. This allows for multiple tiles to have the same name, as long as they are in different tile sets.
Return to Index
new ( string name )
__gc ( )
__eq ( am.tile_set rhs ) -> ( boolean )
name ( ) -> ( string )
full_name ( ) -> ( string )
full_name ( string full_name ) -> ( am.tile_set )
add_tile ( am.tile tile ) -> ( am.tile_set )
remove_tile ( string tile_name ) -> ( am.tile_set )
remove_tile ( am.tile tile ) -> ( am.tile_set )
has_tile ( string tile_name ) -> ( boolean )
has_tile ( am.tile tile ) -> ( boolean )
tile ( string tile_name ) -> ( am.tile )
new ( string name )
Creates a new tile set with the given name.
Parameters:
string name : The tile set name.
__gc ( )
Releases the reference counter on this tile set.
__eq ( am.tile_set rhs ) -> ( boolean )
Compares this tile set with another tile set.
Parameters:
am.tile_set rhs : The other tile set to compare with.
Returns:
boolean : True if they are the same tile set object.
name ( ) -> ( string )
Returns the name of this tile set.
Returns:
string : The name of this tile set.
full_name ( ) -> ( string )
Returns the full name of the tile set. This is used to display the tile set name to the user.
Returns:
string : The full tile set name.
full_name ( string full_name ) -> ( am.tile_set )
Sets the full name o the tile set. This is used to display the tile set name to the user.
Parameters:
string full_name : The new full name of the tile set.
Returns:
am.tile_set : This
add_tile ( am.tile tile ) -> ( am.tile_set )
Adds a tile to this tile set.
Parameters:
am.tile tile : The tile to add.
Returns:
am.tile_set : This
remove_tile ( string tile_name ) -> ( am.tile_set )
Removes a tile from this tile set.
Parameters:
string tile_name : The name of the tile to remove.
Returns:
am.tile_set : This
remove_tile ( am.tile tile ) -> ( am.tile_set )
Removes a tile from this tile set.
Parameters:
am.tile tile : The tile to remove.
Returns:
am.tile_set : This
has_tile ( string tile_name ) -> ( boolean )
Returns true if there is a tile with the given name in the tile set.
Parameters:
string tile_name : The name of the tile to look for.
Returns:
boolean : True if the tile was found.
has_tile ( am.tile tile ) -> ( boolean )
Retruns true if the given tile was found in this tile set.
Parameters:
am.tile tile : The tile to look for.
Returns:
boolean : True if the tile was found.
tile ( string tile_name ) -> ( am.tile )
Looks for a tile in this tile set with the given name.
Parameters:
string tile_name : The name of the tile to look for.
Returns:
am.tile : The found tile, or nil.