BoardTile Object

From BOARD18 Project WIKI
Revision as of 12:09, 4 June 2013 by Rich (talk | contribs) (Initial version of this page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
This page describes a BOARD18 JavaScript object.
This object is created using the BoardTile constructor function.
Go to Object List. - Go to Design Document.

The BoardTile object describes a tile that has been placed on the board.

Data Elements in Object
Element Type C Description
snumb int * Index number of tile sheet object that contains this tile
sheet object * Tile sheet object that contains this tile
index int * Index of tile on tile sheet
rotation int * Rotation of displayed tile on board
bx int * X coordinate of hex containing this tile
by int * Y coordinate of hex containing this tile

An * in the "C" column indicates that the element is created by the constructor function.

Methods in Object

place(tmp) The place function places the tile on the board (canvas1).

togm() The togm function exports the boardTile as a JSON string.