About trialbyfun (twitter: @trialbyfun)

Independent games designer and developer

Dev blog - http://www.trialbyfun.com
Twitter http://www.twitter.com/trialbyfun


Ludum Dare 21
Ludum Dare 20

trialbyfun's Trophies

trialbyfun's Archive

Making of “Mountain above the clouds” – Part 1 – Collision

Posted by (twitter: @trialbyfun)
Thursday, August 25th, 2011 4:32 am

Hi LD48ers,

I’ve had a couple of people ask me about how I put together my 2D game in unity and seeing as the techniques might be relevant in other games I thought I’d take some time to explain some of the things i did in my game, in the hopes that it helps someone out.

like my LD20 game Drum Hammer Dig I chose not to use any external sprite libraries (such as ex2D or SpriteManager), everything game related was written from scratch and there’s of course a link to the source in my compo entry should you want to check it out. ( As you’d expect its all over the place but it got the job done ;))


To start with, i’ll talk about how I handled landscape collision.

One thing I knew early on was that the level shapes themselves were probably going to change a lot as I put the game together. Collision wise I also knew that this game would be 2D, but I didn’t have the time ( or skill ) to write a custom 2d collision system.

Editor shot of the 9 areas

With that in mind I went with the “work with what you have” approach. In this case, Unity fortunatly has a great built in 3D Physics system that i wanted to utilise.

I wanted was to harness that system, in a way that allowed me to quickly create and layout collision without relying on an external 3d package, I also didn’t want to mess around placing lots of box colliders down for each level and then having to move or change them when the level changed.

I chose to write a simple mesh creator in the editor, and then used the generated geometry as a mesh collider. This gave me the best of both worlds. Fast turn around, and all the physics collisions I needed.

Its dirt simple but really effective;

1) First I have an array of points in space ( arranged in a clockwise order )

Points in space

2 ) A set of Vertices is created from these points, extending forward and backwards on the z axis.

Vertex positions based on previous points

3) triangles are created from the vertices

Triangles are created from the vertices

Translated into unity, I have a GameObject for each area in the game which has a “MeshHitcheck” component that contains array of positions (laid out in a clockwise direction)

Using the steps above a collider mesh is generated at runtime from those points.

Background painting on a single sprite

Clockwise layout of points with Gizmo draw in editor to show edges

Hitcheck mesh generated at startup

2D Collision Done!

Same area shot from in game


Editor Extra’s

Hand editing position values in an array isn’t exactly fast so to make editing and layout of the positions array as quick as possible, I created quick little editor helper script that basically draws position handles for each point, and a button to add new points into the array. Its not a perfect solution and there a number of ways to improve it, but it saved me plenty of precious time.

Quick editing of points inside the editor

I should also note that the seed character in game is simply a rigid-body sphere with a limit on the z axis, all other objects are sphere or box trigger colliders that don’t move.

That’s all for today, I hope this was of some use.
If you have any questions or want explanations on some of the other things in game, let me know.

Thanks for reading.

Steven Burgess


TrialByFun – Escape – Mountain Above the Clouds

Posted by (twitter: @trialbyfun)
Sunday, August 21st, 2011 7:54 pm

So I finally did it!

After a slow start coming up with an idea for the theme, i finally found my groove and worked towards finishing my game.

There are a million things I wish I had done differently, things that I needed cut to make the experience feel more cohesive, things that i intended to polish up but didn’t have time, and things that i probably should have taken out.  Audio also took a back seat this time, and i know that’s going to dent the overall experience, but i really was close to the wire as it was. Maybe i’ll have time to put it in a Jam version.

My take on the theme is as follows;

“You play the role of a magical seed that is buried inside the giant mountain. Your task is to escape from the mountain’s belly and into the sky, before it closes its mouth again”


I deliberately limited my palette and stuck to simpler forms as this lends itself better to the rapid design approach and is fairly easy to maintain. Going with a surreal fantasy theme also let me be more bold with art style (strong contrasts, mostly white ) which I hope makes it more visually distinctive and feel less prototypey ( is that a word? ). There are so many improvements I would want to make to this mainly to the character forms, and linework, but i’m still learning, so it’s the best i could do for now :)

Overall, I’ve really enjoyed my second Ludum Dare ( I’m shattered though!). Interestingly, and more so than “Drum Hammer Dig”, I really feel like this game can be expanded on into a much larger experience, so i intend to come back to this game in the future.

In the meantime enjoy;


Please let me know what you thing. What you liked and didn’t like either in the comments or on twitter @trialbyfun
Thanks to you all.

Progress – Part 3 – I’m done. Drum Hammer Dig

Posted by (twitter: @trialbyfun)
Sunday, May 1st, 2011 4:57 pm

Presenting “Drum Hammer Dig”

I’ve got as far as i’m going to get before the deadline without breaking something.

Its been an exhausting, but enjoyable experience and a great learning experience.

Its also been a double set of firsts for me, first Ludum Dare, and first game i’ve completed (well, as good as it gets in 48 hours ) since becoming and indie.

There’s plenty of things I would like to do to this game (if i ever come back to it), such as add more levels or perhaps dynamically generate them, more items, ways to kill the enemies and other lovely effects. But its resting time now.

In the meantime please check out my entry


All feedback welcomed. Its been a pleasure.




Good luck to all those people still working on their games for the final 2 hours.

Progress – Part 2

Posted by (twitter: @trialbyfun)
Sunday, May 1st, 2011 11:03 am

It might not look fancy but it functions and plays pretty nicely.

All the major game logic is in and the main game states;

  • Start Screen
  • Sample level
  • Time over screen
  • Death screen
  • Success screen

Even though there is 8 hours remaining, i’ll probably only be able to spend another 4 on this. In that time, i’m going to focus on presentation side. Audio, animation and graphics polish.

This has been tough… but fun.

Progress part 1

Posted by (twitter: @trialbyfun)
Saturday, April 30th, 2011 11:55 am

After getting back from shopping, I did a little brainstorming about the game. One thing led to another and i eventually settled on this idea.

In short it’s “Exploration vs Minesweeper”

The basic idea is this. You play as a little character who has been sent into a mysterious cave with the aim of reaching the other side and all the glory that holds. Its dark, cramped and scary in the cave, and the place is sure to be filled with monsters at every turn but you don’t know where!

Upon reaching the cave (totally unprepared for venturing in) you are given a magic hammer by a passing stranger (how mysterious). He explains to you that by tapping on a wall with the hammer it will reveal what lies beyond the wall for a very brief time.

Using this knowledge you must decide whether to knock the wall down, and move further into the cave, or try another wall.

If you stumble across an enemy it will kill you, not even the mighty hammer will be able to avert your fate.


Right now all I have is the tile reveal part working, and a rough echo reveal effect (the numbers)

Next i’m going to work on putting the character in which moves around the cave and the basic game logic. (i.e hammering, moving)

Graphics will be up-rezed at the end time permitting, as right now i’m more focused on the gameplay side.

The Adventure Begins

Posted by (twitter: @trialbyfun)
Saturday, April 30th, 2011 3:37 am

Literally this second just found out the theme. Okay, Interesting.

A couple of ideas have sprung into my head, but I need to go food shopping first [ That’s life ] . I’ll let the ideas simmer in my head between the dairy, veg and snacks section.

1 day 15 hours remaining.

[cache: storing page]