Hi everyone (first post) :)
It looks like the following code (using the "old" TileMapAtlas class) works as expected:
TileMapAtlas *tilemap = [TileMapAtlas tileMapAtlasWithTileFile:@"tiles.png"];
tilemap.anchorPoint = ccp(1.0f, 1.0f);
tilemap.position = ccp(480,320);
That is: the tile map is displayed with its top-right corner placed in the top-right corner of the iphone screen (landscape).
However, the following code (using the new TMXTiledMap) does not work as expected:
TileMapAtlas *tilemap = [TileMapAtlas tileMapAtlasWithTileFile:@"tiles.png"];
tilemap.anchorPoint = ccp(1.0f, 1.0f);
tilemap.position = ccp(480,320);
...instead, the tile map is displayed with its BOTTOM-LEFT corner placed on the top-right corner of the iphone screen (resulting in nothing to be displayed as shown next):
----------
| tile map |
------ ----------
|screen|
------
Basically, the anchor point is being ignored.
Furthermore, the following text can be found in the class documentation:
"The anchorPoint of the TMXTileMap is (0,0)"
Does that mean we cannot change it?
I guess I could leave with that if it wasn't because of scale transformations: they seem to use the anchor point as a reference and zoom in/out animations feel "weird" when scaling versus the (0,0) coordinate.
Any idea ?
Thanks and keep up the good job :)