examples/isometric_rpg/js/screens/play.js
function (event) {
                var tile = this.refLayer.getTile(event.gameWorldX, event.gameWorldY);
                if (tile && tile !== this.currentTile) {
                    // get the tile x/y world isometric coordinates
                    this.refLayer.getRenderer().tileToPixelCoords(tile.col, tile.row, this.diamondShape.pos);
                    // convert thhe diamon shape pos to floating coordinates
                    me.game.viewport.worldToLocal(
                        this.diamondShape.pos.x,
                        this.diamondShape.pos.y,
                        this.diamondShape.pos
                    );
                    // store the current tile
                    this.currentTile = tile;
                };
            }
function (event) {
                var tile = this.refLayer.getTile(event.gameWorldX, event.gameWorldY);
                if (tile && tile !== this.currentTile) {
                    // get the tile x/y world isometric coordinates
                    this.refLayer.getRenderer().tileToPixelCoords(tile.col, tile.row, this.diamondShape.pos);
                    // convert thhe diamon shape pos to floating coordinates
                    me.game.viewport.worldToLocal(
                        this.diamondShape.pos.x,
                        this.diamondShape.pos.y,
                        this.diamondShape.pos
                    );
                    // store the current tile
                    this.currentTile = tile;
                };
            }
function ( event ) { var tile = this . refLayer . getTile ( event . gameWorldX , event . gameWorldY ) ; if ( tile && tile !== this . currentTile ) { // get the tile x/y world isometric coordinates this . refLayer . getRenderer ( ) . tileToPixelCoords ( tile . col , tile . row , this . diamondShape . pos ) ; // convert thhe diamon shape pos to floating coordinates me . game . viewport . worldToLocal ( this . diamondShape . pos . x , this . diamondShape . pos . y , this . diamondShape . pos ) ; // store the current tile this . currentTile = tile ; } ; }
pointer move event callback
pointer move event callback