# Love2d: Failed to load tileset map

I'm reading the Love2D Development book, which i think i will stop reading because is outdated and very instable, sometimes i got a lot of troubles. Backing to the question, i made a tileset map with Tiled and saved in .tmx with Base64 ( uncompressed ) then i used Advanced-Tiled-Loader and used the code from the book:

-- This is the main.lua file --

---the path to our .tmx files and sprites

love.graphics.setBackgroundColor(255, 153, 0)

--- load the level and bind the variable map

end

function love.draw()

map:draw()

end


When i tested the game, the result was this:

http://i.imgur.com/JM8EYrv.png

The result was suposted to be like this:

http://i.imgur.com/W26XFjE.png

So what it could be?

• You should probably take a screenshot instead of a picture of your screen. These pictures are pretty blurry. – Heckel Aug 5 '14 at 2:30
• yeah, i couldn't take screenshot, i will try to fix it.. – RebeloX Aug 5 '14 at 2:42
• – Anko Aug 5 '14 at 11:49
• @Anko Thanks dude, i already upload the images and edited the question.. – RebeloX Aug 5 '14 at 22:44
• Did you place the tilesheet you used in the map folder? Also ATL is a bit old, better to use; love2d.org/forums/viewtopic.php?f=5&t=76983 – dan369 Aug 6 '14 at 0:35

-- This is the main.lua file --

---the path to our .tmx files and sprites
local map = nil;

love.graphics.setBackgroundColor(255, 153, 0)

--- load the level and bind the variable map

end

function love.draw()

map:draw()

end


So using my copy of ATL, and just making a quick test tiled map, this code worked fine. Using base64. Should look like; http://i.imgur.com/esHoetm.png

Map: http://pastebin.com/k05iHYhs & my test sheet; http://i.imgur.com/j2SuFcX.png

For clarity & any future reference ATL is a bit outdated, doesn't support polygons/polylines that are available in Tiled. It does however support older versions of LOVE. Whereas the atlernative; STI requires LOVE 0.9.1 but does provide updated support (Link)

• I used your code and it works, probably it is some error that i got from the tmx file. About the STI, my computer doesn't support OpenGL 2.1+ , so i can't use that library. – RebeloX Aug 8 '14 at 17:28
• Ah well glad I could help :). – dan369 Aug 8 '14 at 21:05
• I created a tileset with your tile image and it worked, but when I use the other image it goes crazy, like that image that i have shown. What it could be? Could I be setting someting wrong in Tiled? – RebeloX Aug 8 '14 at 21:59
• What is your tile-size? It could be that (from your previous image it saw your ts as 16x16 (my guess) whereas i've only tried ATL with 32x32 tiles). – dan369 Aug 9 '14 at 2:00