Description

Transforms positions tile to real positions. Return an object

  • x : Position X in pixels
  • y : Position Y tile in pixels

Usage

Parameters

  • tile_x {Integer}

    Tile X

  • tile_y {Integer}

    Tile Y

Returns

Object

Example

// if tile is 32*32px
RPGJS.Map.tileToPixel(2, 3); // returns {x: 64, y: 96}

Discussion