Skip to content

Commit 6312325

Browse files
committed
Add clairifying note to fix phaserjs#3193
1 parent 532715d commit 6312325

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/gameobjects/tilemap/Tilemap.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,8 @@ var Tilemap = new Class({
214214
* Turns the StaticTilemapLayer associated with the given layer into a DynamicTilemapLayer. If
215215
* no layer specified, the map's current layer is used. This is useful if you want to manipulate
216216
* a map at the start of a scene, but then make it non-manipulable and optimize it for speed.
217+
* Note: the DynamicTilemapLayer passed in is destroyed, so make sure to store the value
218+
* returned from this method if you want to manipulate the new StaticTilemapLayer.
217219
*
218220
* @param {string|integer|DynamicTilemapLayer} [layer] - The name of the layer from Tiled, the
219221
* index of the layer in the map, or a StaticTilemapLayer.

0 commit comments

Comments
 (0)