Skip to content

Commit

Permalink
Includes image collection offsets
Browse files Browse the repository at this point in the history
  • Loading branch information
zekeatchan committed Jan 21, 2025
1 parent 831a06f commit c145f73
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/tilemaps/components/RenderDebug.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,11 @@ var RenderDebug = function (graphics, styleConfig, layer)
{
var tile = tiles[i];

var offset = tile.tileset ? tile.tileset.tileOffset : { x: 0, y: 0 };
var tw = tile.width;
var th = tile.height;
var x = tile.pixelX;
var y = tile.pixelY;
var x = tile.pixelX - offset.x;
var y = tile.pixelY - offset.y;

var color = tile.collides ? collidingTileColor : tileColor;

Expand Down

0 comments on commit c145f73

Please sign in to comment.