englercj / phaser-tiled

A tilemap implementation for phaser focusing on large complex maps built with the Tiled Editor.
MIT License
290 stars 31 forks source link

Option to obey Tiled's renderorder. #66

Closed MannyC closed 8 years ago

MannyC commented 8 years ago

Sorts tiles based on the renderorder given by Tiled if the map's obeyRenderorder is set (defaults to false).

Allows for 2.5d maps, or maps with oversized tiles.

Does impact performance if enabled.

As an aside, I happened to notice that the tilelayer always adds children to itself as if it was always going to have tiles covering the screen, which isn't the case with sparse maps, which could make quite a speed difference for a sorted sparse map.

I'd hope to have a more advanced sorting method eventually, this is just to enable the functionality.

englercj commented 8 years ago

Nice, is this a solve for #38?

MannyC commented 8 years ago

Well, kind of. I think #38 is based on an older phaser-tiled version because the current version allows tiles that are larger than the grid. So, it would solve his ordering issue but he actually says he'll need a non-supported ordering anyway. So ... kind of :)

englercj commented 8 years ago

haha, thanks for this!