We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1f72b90 commit 1334914Copy full SHA for 1334914
1 file changed
src/gameobjects/tilemap/Tile.js
@@ -554,6 +554,20 @@ var Tile = new Class({
554
{
555
return this.layer.tilemapLayer;
556
}
557
+ },
558
+
559
+ /**
560
+ * The tilemap that contains this Tile. This will only return null if accessed from a LayerData
561
+ * instance before the tile is placed within a StaticTilemapLayer or DynamicTilemapLayer.
562
+ * @property {Tilemap|null} tilemap
563
+ * @readonly
564
+ */
565
+ tilemap: {
566
+ get: function ()
567
+ {
568
+ var tilemapLayer = this.tilemapLayer;
569
+ return tilemapLayer ? tilemapLayer.map : null;
570
+ }
571
572
});
573
0 commit comments