This weekend was the weekend of Ludum Dare. An online game jam where people from around the world create a game each in one weekend. The concept and background is explained quite well in the Ludum Dare Wikipedia entry so I won’t go into details here, except to say that the games have to try and follow a theme, and this time the theme was Minimalism. Since my wife and son are visiting family in Denmark, and I’m between jobs, I found that I suddenly had the time participate.
The thing I am the most proud of, coming out of this weekend, is that I finished my first game.
I chose to write it using HTML and JavaScript because of the accessibility it gave, and because those technologies will be part of my day job very soon. A game becomes much more accessible to people if they can play it in the web browser, rather than downloading, potentially installing, and running it on their machine.
Based on my technology choice I evaluated a few different game engines, and ended up choosing Crafty. While I did run into some problems with the engine, a few minor bugs that I hope I have a chance to tackle, and some documentation ambiguities, it still feels like it was a good choice. I did find a couple of articles comparing JavaScript game engines later, which I wish I had time to read before, but settling on tech and engine was a definite boon. It would have been nice if I had experience with the engine before, but since I didn’t have experience with any engine, that would have been hard.
I very quickly decided on a basic gameplay and art style, although I diverged a little bit from it when I started getting pressed for time. The basics still revolve around a blue ghost as the protagonist, red demons as the enemies, green ectoplasm for “ammunition, as well as black and blue elements representing walls and water. I wish I had time to design some proper wall and water tiles, but I didn’t even have time to use my thing or the Hell Hole itself. The thing was this orb you could pick up, and had to put into the hell hole to close it, and the hell hole would (obviously) spawn demons.
Before I start getting into the stuff I learned from this experience, you can open a new window and play the game in your browser, I’m not going anywhere.
Hell Hole -- Ludum Dare entry for the theme Minimalism
Now that you’ve tried it I’m sure there’s a number of things that have become apparent. First of all, this game is insanely hard (unless you found the same speed cheat1 a friend did within 10 minutes2). And sometimes, you can only move a short distance to the right before the viewport stops and you kinda step off the world. You can still die when outside the viewport, but you cannot see the little ghost or the demons
Secondly, if you made it that far, the goal is to kill all the demons and then you win. Easy right? What was that? You killed all the demons, and still didn’t win? That’s right, I forgot to put a screen in that told you when you won. Instead you are stuck in an empty world and the only thing you can do is to refresh your browser window.
Both of these boil down to the biggest problem I ran into: the time pressure. When you have to create a game in 48 hours, you really have to focus on the core and forget all the fluff. Which is definitely my biggest takeaway from this weekend.
Things that are done on purpose is that you can walk through walls, but you cannot cross water (basic ghostology). Similarly to the problems above, I wanted the demons to not pass through walls, but be able to cross water. This would give a different mechanic for hunting the demons.
I got caught off guard by a few things. First off, I thought the theme was announced (and the competition started) at midnight Friday. Turns out it started at 7 pm PDT. So I lost a few hours there. Not a biggy though. I spend the rest of the evening brainstorming ideas before going to bed, to be fully rested to start making my game Saturday.
When I got up Saturday I brainstormed look and feel, I sketched art, I researched story. I wanted something that people could play and go “wow, that’s a cool story.” Unfortunately, doing that meant that the mechanics never got the polish I felt they needed, and never got around to using my nice art or my elaborate story.
In the end Saturday was mostly spent doing sketches, some simple sprites (that didn’t get used either), story, and some very simple gameplay using this introduction to Crafty tutorial. The feeling when I woke up Sunday morning and realized I had basically nothing with 7 hours to go, is perfectly encapsulated in this tweet:
7 hours to go is when you start saying things like "who needs walk cycles." #LD48
— Jonas Rabbe (@somebear)
This was when I decided to fall back to 16 × 16 pixel sprites (rather than the 40 × 40 pixel beauties I had envisioned) blown up 4 times to give a retro look. Almost all animations went out the door, and only simple animations when you kill a demon or when you die stayed in.
One of the things that became abundantly clear, was that the time I spent on story was wasted. While I think story is definitely great in a game, the entries that do well in Ludum Dare and other game jams are those that choose one core mechanic and polish it to an incredible shine. Zen fighter is an example of such a game, its mechanic is in its controls and they work incredibly well. Since I became so pressed for time, I also didn’t have the opportunity to use the story at all, and the time spent on developing it could have been better spent polishing the mechanics.
For the competition Hell Hole uses a simple rectangular grid based game world with auto-generated content. The demons start following you if they come within 250 pixels of you, which means that sometimes you spawn, and a demon spawns right next to you (i.e. you’re dead). When you die the whole world is regenerated, so you start from scratch. Because everything is autogenerated semi-randomly, so you also run the risk of starting completely boxed in with nowhere to move.
After the end of Ludum Dare I fixed a few things. I added a win condition (which is allowed within the rules), and added some instructions. I also fixed the viewport following bug by using Austin Hanson’s bmViewport which makes for a much more enjoyable gameplay. This version is also available online:
Things I wanted to get around to
Because of my time mismanagement, there were so many things I didn’t get around to. As I’ve already mentioned I wish I had time to use my story, but for the next LD48 I participate in, I’m definitely going to ditch story and make a game with a very simple mechanic that is polished to feel great.
The AI for the demons is a simple sight based model. If you get within a distance of 250 pixels (roughly half the viewport) of a demon, it starts following you. This means that you can see demons at the edge of the viewport before they start following you, so you can run away. I wanted for the demons to do some kind of random walk. I also wanted the demons to not pass through walls, but to be able to cross water, and I wanted them to not be able to see through walls.
Finally, I wanted to have the Hell Hole which spawned demons, and you would be absolved once you use the thing to close the hell hole and kill any remaining demons.
I’m sure I’ll get around to fixing some of these things, but enjoy what’s there, it’s my first game.
The source code can obviously be downloaded from the pages above, but the whole project is open source, and can be fetched from the Hell Hole Repository.
The game uses WASD and the arrow keys for controls, and if you press both W and the left arrow key, then you go at double speed (for now). ↩︎
Thanks a lot, Enamckin. ↩︎