Is it possible that all tiles on the map have to be a fixed tile size (i.e 8x8 in my case) to be added to the data table inside every layer?
I use following code to check if anything is inside the data table:
Code: Select all
-- Place pads
for y = 1, #map.layers["objects"].data do
for x = 1, #map.layers["objects"].data[1] do
if map.layers["objects"].data[y][x] then
local sx, sy = map.layers["objects"].data[y][x].w, map.layers["objects"].data[y][x].h
pads[#pads+1] = newPad(x, x*sx-sx, y*sy-2, 48, 2)
end
end
end