toto88x Posted March 3, 2014 Share Posted March 3, 2014 Hi, I'm trying to do a tilemap with a .csv, and I have two questions. 1- In my code I have "game.load.tilemap('map', 'map.csv', null, Phaser.Tilemap.CSV);", and I get an error: "Uncaught SyntaxError: Unexpected token , phaser.min.js:11 c.Loader.jsonLoadComplete _xhr.onload". If I comment the load.timemap line, the error is gone. Am I doing something wrong? 2- Then, how should I display my csv map? I used a JSON code example that I tried to adapt. Is it correct?var map = this.game.add.tilemap('map');map.addTilesetImage('tiles'); var layer = map.createLayer(1);layer.resizeWorld();Thanks for your help! Link to comment Share on other sites More sharing options...
rich Posted March 3, 2014 Share Posted March 3, 2014 Sorry this is broken in 1.1.6. However I literally just fixed it in 1.2 branch, along with allowing you to create completely blank / empty maps and populate them dynamically. Link to comment Share on other sites More sharing options...
rich Posted March 3, 2014 Share Posted March 3, 2014 So in the meantime in 1.1.6 you have to use Tiled to export your map data I'm afraid. Link to comment Share on other sites More sharing options...
Recommended Posts