Warpigs Postmortem – Part 1

Posted by (twitter: @_sorceress)
May 6th, 2014 5:31 pm

Day One Summary

Day 1: Morning
I woke at about 8am. I powered up my computer, got breakfast, and mulled over the theme while chatting on IRC.

I decided pretty quickly that I would make an overhead 2D game that involved strip mining the land. I had no real idea what the game would become at that time. My first task was to draw some terrain textures, and get code in place to render a terrain.

I realised straight away that to make the terrain look nice, there would have to be nice transitions between the different terrain types. And I really needed a minimum of 4 types: grass, dirt, water, and land that had been stripped.

Blending between two tile types is easy, as the transition can be part of the texture proper. But with 3+ tile types, the sheer quantity of transition tiles becomes unrealistic to draw. After some discussion about this on IRC, I decided to do layered textures (which was the solution I was leaning towards anyway).

This means that many kinds of terrain can be drawn with transparency, stacked on top of each other. I wanted to get this up and running with a scrolling camera by noon. Which I did much to my delight with literally 5 minutes to spare.

day1-01

 

Day 1: Afternoon
Throughout the morning, I had developed a couple of different ideas for what this strip mining would be about: It could be people digging for gold and gems, birds digging for worms, or pigs foraging for truffles — either way it would be generating an income for buying stuff.

With my fondness of the strategy genre, this harvesting mechanic reminded me of Warcraft II. The idea of using income to buy fighting units to stop enemy harvesters appealed to me. So that was my goal.

I’d attempted to make an RTS once before for LD24, but that didn’t go to plan. The difficulty with it was:
– It was 3D, which needs more work for pretty much everything.
– Path-finding took too long to set up.
– Combat system was over-complicated.

My game this time was 2D. I needed to ensure I had simple path-finding and simple combat system.

So it was now time to start making some characters to populate this land. My first attempt at drawing birds was not very successful, and I feared that pigs would all look alike. So I settled on human characters with pig workers.

The basic character sprite was drawn and animated, and then copy-pasted, modified and recoloured into six other characters. All together that drawing took me about 3 hours.

The next couple of hours before dinner were spent adding units into the game, and perfecting their collision detection/reaction.

day1-02

 

Day 1: Evening
As day one passed the half way point, my next step was to add unit group selection. And since orders can be targeted at both units or areas, I needed to be able to differentiate between clicking points on the terrain and clicking on units. I tested this initially by having units follow other units if I right-clicked on them, or simply to move to the clicked point if I right-clicked terrain.

I spent all of the evening fleshing out this order handling system, as it was the core of the game engine. This included writing an auto-attack subroutine, whereby units could assign themselves an attack order if there are hostiles nearby.

day1-03

 

Day 1: Night
By about 10pm, I realised I needed a HUD! No good me having this fancy order handling system if I couldn’t select which order to assign!

The button images were drawn at this time, mostly by copy-pasting bits from my sprite sheet. Plus I wrote a few lines of code to detect the mouse hover/click events over the buttons. The HUD wasn’t functional at this time.

At around midnight, I started writing my game music. This took me about 2-3 hours more I think. I’m not sure when I fell asleep.

day1-04

 

http://www.ludumdare.com/compo/ludum-dare-29/?action=preview&uid=5745

 


Leave a Reply

You must be logged in to post a comment.

[cache: storing page]