Search the Community
Showing results for tags 'isometric-plugin'.
-
I'm having a terrible time getting my tiles to align properly. I'm using the following routine to print them: var size = 54; var i = 0; for (var xx = 0; xx < size * this.mapData.MapWidth; xx += size) { for (var yy = 0; yy < size * this.mapData.MapHeight; yy += size) { var row = Math.floor(i / 10); var col = Math.floor(i % 10); var assetId = this.mapData.MapTiles[col][row].AssetId; var asset = this.game.AssetManager.getAssetById(assetId); tile = this.game.add.isoSprite(xx, yy, 0, asset.Name, 0, this.tileGroup); tile.smoothed = false; tile.body.moves = false; tile.snap = 1; tile._project(); tile.anchor.set(0.5, 1); console.log("Placing (" + row + "," + col + ") at (" + xx + "," + yy + ") which is (" + tile.position.x + "," + tile.position.y + ")"); if (asset.Name == "water01") { this.waterTiles.push(tile); } i++; } }But I'm still getting these little slivers of space between some tiles and noticeable nicks in the map border, no matter what I adjust size to http://imgur.com/xFt3OfN 96 x 48 is the diamond size, tiles have a 4px bottom on them making the images actually 96 x 52 I'm not really sure what the problem is. I'm not sure how to pick a good value for size... any help would be great. Thanks!
- 3 replies
-
- isometric
- isometric-plugin
-
(and 2 more)
Tagged with: