Box2d Light Example

I’m not sure how to do it either, I’ll let @britzl help with this.

it rather fits defold-tiled example more

I’d say it’s a separate topic on how to install luarocks for Lua 5.1?

1 Like

Try this.

luarocks --lua-version 5.1 install ... 

Yes, this about box2d light not about tiled. I use tiled because real game use tiled and it was much easy to me for make example. You can use light without tiled parser:)

If you can’t use luarocks in your pc. You can try parse levels from game.
Test it on windows. it worked.
1)Add lfs dependency
https://github.com/britzl/defold-lfs/archive/master.zip
2)Make fixes in parser.lua. Make function that will parse tiled.

3)Export from tiled to .lua files(by your script)
4)Run game first time. It will parse levels.And save it in your pc filesystem.
4.1)You will not see changes because game load levels from bundle files, not from system
5)Run game. You will see changes.

Good luck :grinning: :+1:

2 Likes