Skip to content

This Week in LesserPanda #8

Sean Bohan edited this page Jun 15, 2016 · 1 revision

Covering the days from 2016-06-10 to 2016-06-15.

Collision map with holes are finally supported due to this week's hard work, and you know what, shapes designed from Tiled collision editor will now import automatically which will hugely improve tilemap based level design workflow.

tilemap-animated

Collision map with holes

Previously I've worked hard to make it possible to merge tile collision layer into convex polygons to improve the performance and get rid of hacks of tilemap collision solvers used by other engines. Those hacks are ugly and hard to understand, and so you are limited to what it brings. That's the reason that motivate.

What is "holes"?!

A picture is more than thousands of words :D

tilemap-with-holes

Tiled "tile collision editor" support

Tiled has a great feature: customize collision shape of each tile. That is what I've been thinking at the very beginning of making the new tile collision support. It's eventually finished now and I can sleep well tonight :D

In case you are not familiar, I make a short guide for you.

How to use Tiled collision editor

Collision editor is a tool to design collider shape of a single tile. So you need a tileset to work with.

Here's the tileset I used for collision layer.

tiled-collision-tileset

Select the one to edit and click "View > Tile Collision Editor" to open the editor window.

tiled-collision-editor-window

Now use the shape tools to draw whatever you want. (Note that only ONE shape per tile is supported, which is more than enough IMHO)

tiled-collision-editor-triangle

Small tip: turn the snapping on to draw easily.

tiled-turn-on-snapping

Done, now you have a tile with collider shape defined properly.

How to use the collider shapes in LesserPanda?

Nothing needs to be done, it just works :D

What's Next

Since Tiled based workflow is almost done, a complete demo with everything will let you feel more than just reading about it here. Keep waiting no more than a week for it, and you'll be happy.

As you may remember that I was working on an official LesserPanda editor. I've done the whole new design and may start to work on it next week. Tiled is supported much better now, but still far from the convinence of in-game editor, especially when place and setup Actors.