September 30, 2007

Next Flash game underway

Scrolling stars!

The next game in ActionScript 3.0 Game Programming University is a shooting game called “Air Raid”, where you move a cannon from left to right to shoot down aircraft. However I’ve decided I’d prefer to branch out a little and make something else up vaguely in the same area. I settled on an old school style arcade scrolling shooter along the lines of Galaxian or Galaga. I figure it’s time to start to learn from trial and error by making more of the decisions on the program structure and programming.

So far all I’ve got is a few choice fonts (from Larabie Fonts like with the other games; Ray Larabie has brilliant free fonts for games) and a scrolling star field. The star field has taken me a little while to do. It’s got through a few iterations and I’m still not very happy with it. It’s a little bit jerky even though I’m using time based movement, and I don’t know whether that’s a limitation of Flash or I’m doing something wrong.

My first approach to the star field was to have an array of star sprites that move down the screen. My second approach was to draw the stars individually onto a single star field sprite every frame. I actually tried both approaches at the same time as I wasn’t sure which would be best. I found that there didn’t seem to be much of a difference between the two - they both were okay, but they both stuttered in movement.

My next approach was to render all the stars at creation to sprite layers saved as bitmaps, and to scroll the layers down the screen. I used two identical sprites per layer so I could have them seamlessly wrap from top to bottom. There were some weird motion effects on the two sprites where they weren’t moving at quite the same speed, which I suspect was due to floating point errors. I’ve now got them working on a variant of fixed point and got both sprites moving in lock step, but there’s still a bit of animation stutter.

I might be overreacting since it isn’t that bad, but I’m curious as to whether there’s a way to getting the scrolling silky smooth in Flash. For now it’s good enough, and I’ll move onto planning out the game.

Additional: I’ve just noticed that the PNG screenshot of the Flash file is several times larger than the Flash file itself. I might as well just post the whole darn thing instead of a still picture!

The thumbnail link now goes to a copy of the Flash file. It might be nice to have a couple of copies of works in development to compare against.

Permalink • Print • 1 Comment

September 29, 2007

Flash Game #2: Code Breaker

It’s the long weekend, and instead of sleeping in I’ve finished off my second Flash game, Code Breaker. This is from the fourth chapter of the Game University book; the gameplay is essentially the same, but I spend a while modding it extensively to get a feel of how to layout things in Flash.

Here’s the link to Code Breaker

The game is essentially the same as the board game “Mastermind”; the computer chooses a random code of coloured panels, and you have to deduce the code. Click on the grey panels to cycle through colours to make your guess and hit the Done button, then lights will give you clues on the code. A green light indicates you’ve got a coloured panel in the right spot in the order (but it won’t tell you which one!). A red light indicates you’ve got a coloured panel in your guess that’s somewhere in the code, but you’ve put in the wrong spot. You’ve only got ten guesses to try and crack the code.

One thing that mightn’t be obvious is that the default grey panels can be left in your guess, but are never in the secret code. You can use these to your advantage if you only want to focus on a bit of the code at a time.

Tell me what you think; I’m going to start looking into what I’ll make next.

Another link to Code Breaker for good measure

Permalink • Print • 2 Comments

September 28, 2007

Scheduled Mac downtime; more 4E6 musings

It probably wasn’t the smartest move to read the 4E6 elements at 1 a.m. this morning. I must have had ponies and accountants and pony accountants running through my brain for the last 15 hours. Consequently my productivity wasn’t the best in terms of research output. But then again, it’s Friday in front of a long weekend, so it’s not like that was unexpected.

I’ve just learnt from the local Apple store that the replacement screen for my MacBook Pro is almost ready, so they can fix my pixel damaged screen next week. That’s pretty good news; I wasn’t sure if it was damaged enough for them to replace with nine to a dozen dead pixels. It’s mainly an irritant than something totally dehabilitating to work, although the cluster on the end is a pain, and it’s annoying when I try to lean in to look at something closely, which happens now and again when you work in computer vision and with art. But I’m pleased with their customer service, and it makes me more likely to buy a Mac Pro as my next desktop replacement so it’ll be a win for them in the long run too.

This means that I’ll be Mac-less for much of next week, so I won’t be doing much work directly with Flash. As a consequence I might move my long weekend tasks of updating the website back to the middle of next week, as I can do that on my ol’ Windows box. I’ll also look into other things I can do without my main software tools, like designing some ActionScript classes, writing some articles or maybe a bit of C++ programming.

As I mentioned before, I’ve been spending (too much) of today musing about 4E6. If you’re interested in following the contest you can consider me as joining in this year, at least for now. I don’t know how far I can go before the time pressures get too great, but it’ll be a fun academic exercise in game design.

This year 4E6 contestants can choose three of the four elements to include, or to put it another way they can throw one out. In the early stages it’s a nice exercise to figure out which elements suit your design style the best.

For me, it’s pretty much a given that whatever I end up making will be cute and/or retro - pretty much all my game ideas fall into one of those categories; that’s my niche. I’m also committed to using Flash this year; I’m considering this as part of my Flash game development strategy. This means 2D, vectorised graphics, possibly web based, mouse based control preferred.

With that in mind, it’s pretty clear to me that “ponies” and “crystals” should be in the game; that’s prime cute material right there. The two can pretty easily work together in a number of ways, too. The question then is which out of “accountants” and “explosions” do I have as the third, or whether I include both.

I’ve got a few ideas for those two elements, although I’ll need to brainstorm them up a bit more with a clearer head. I’m hoping I can factor in accounting as some kind of financial management side to a game, and explosions can easily fit in as a special effect if they aren’t too much of the violent kind. It probably won’t be too difficult to factor in both of these after all.

Lots to consider though - still very early in the game development process, but there’s also a lot of Flash learning to go before I can make something sizeable enough for a contest piece. Stay posted.

Permalink • Print

4E6 - First Impressions

Only one more weekday before the long weekend. Most people celebrate Labour Day by not doing any work, but I’ll use some of the extra time to make some general improvements to the website. I’ll also be continuing with learning Flash game development. I’ve got my next game almost finished - the core gameplay is done, I just need to put the finishing touches on the graphics and the sound effects. I’ll probably have that up later today, and I can start work on another game on the weekend.

For those of you interested at the happening at, the Four Elements VI contest is underway. The elements this year are very… random. “Ponies”, “Accountants”, “Crystals”, and “Explosions”. The general impressions I’m getting from the forum is that the element choices are very polarising; some really love them, whereas others are turned away.

I must admit my first impressions of the elements are a bit lacklustre. They seem like they’re trying a bit too hard to be “out there”. They didn’t at first really strike me as elements that make me want to rush out and design a game. Now I’ve had a bit of time to think about it I’m starting to get a few sparks of an idea but it’s still a bit muddled. I’m glad there’s only a three element limit this year.

I’ll stick up a poll about the elements this weekend once my current poll has run its course. I’ll be interested in seeing what your views on the elements are. Here’s a quick snapshot of mine.

Out of the elements, “crystals” is the one I like the most: it’s got a lot of potential to be taken in a number of ways, and it can fit it nicely with any of the other elements. However “ponies”, “accountants” and “explosions” all have the problem that they negate each other as themes. “Ponies” suggests cute, safe, magical environments, which doesn’t go well with the raw destructive power suggested by “explosions”. And, no offence to any accountants out there, accountancy strike me as a rather flat and dull element to put in a game. Taken individually they can work well, but my impression is that the general essence of only one of those three elements can be brought to bear at any one time, with a danger that the other two will be merely tacked on.

Additionally, “accountants” sticks out to me as the odd element out from the four. It’s very specific. It’s not something general like economics (from last year) which could be taken in a number of different ways. Even “accountancy” would be more general, as that doesn’t suggest you need an actual accountant in the game. I’m not sure exactly why, but I’d feel better if the element was a bit more general, say to include bookmakers or insurance claim assessors or something.

Overall I expect there will be a lot of parody type games that only scratch the surface of most of the elements. I’m hoping there’ll be one or two that can blend the elements in an unexpected way though - it might be tough to fully do justice to all four.

As for me, I may enter this year. Given my time constraints I’ll only enter if I can think of a game I can prototype up in a week, which limits down any grandiose ideas from me (nothing in the vein of Mop of Destiny, I fear). That being said I have the kernel of an idea that incorporates all four that might be serviceable - I’ll see what I can sketch up over the weekend.

Permalink • Print • 2 Comments

September 25, 2007

Tile Match - My First Flash Game

Tile Match - My First Flash Game

It took me a little bit longer than I expected, but I’ve got a Flash game up and running. I’d forgotten how many little things crop up when making a game, such as making sound effects, testing and all the other random things that get in your way. Having 4E6 announcements along the way didn’t help!

Here’s a link to a webpage for the game; it’s pretty much the same as the one that Flash spits out during its publishing phase as I haven’t yet decided what format I’ll go with for these things.

The game itself is a simple tile matching game; find pairs of matching tiles by clicking on them. It’s pretty much the same as the game described by Gary Rosenzweig in chapter three of his ActionScript 3.0 Game University book, except I prettied it up a little bit.

I’d love feedback on the game! I’ve tested it myself over the Internet and it seems to work fine, but if there’s anything obvious I need to fix let me know. I’m new to whole Flash thing so I’m sure I’ve committed a few blunders in there.

Link again in case you missed the other two.

(You might need to get the latest Flash player for the game to work.)

Permalink • Print • 8 Comments

4E6, soon

After a fair delay it looks like the Four Elements contest will be underway very shortly - dates listed and everything. I always like during the first few months of a Four Elements contest; everyone in the journals bounces around ideas and gets cracking on development. Usually things start losing steam about half-way, but there’s usually a project or two that lasts the distance.

I’ve always kicked myself for not entering something in each Four Elements contest, so I’m somewhat keen to try something for this year. The gargantuan problem is the timing with regard to my Ph.D. candidature. I’m in the tail-end of my research right now; wrapping up the theory, getting ready for some core experiments, and writing up my dissertation. My planned finishing date for my Ph.D. is roughly the same time as the finishing date for 4E6, so things will only get more hectic as time goes on.

Because of this, I can’t say for sure whether I’d enter or not. If the elements are favourable, then I’m strongly hoping I can put together a small Flash game in a week or two. Whatever I decide to do there’s very little chance I can get much done in the last month or so of the contest time line.

Even if I don’t manage to get an entry done this year, I’ll be very keen to see what everyone else gets done. I’ll probably have the time to try them out in April after I submit.

Permalink • Print

September 24, 2007

Taking my first step in Flash game development

I know this is just after my poll result post, but since I’m using WordPress now it makes better sense to split unrelated topics off into their own posts. I get email notications on every reply, so it’s not as if someone’s useful comment will get lost along the way.

I spent a chunk of the weekend working through the first two chapters of ActionScript 3.0 Game Programming University. These chapters cover the basics and a bunch of universal elements, many of which are analogues of the sorts of techniques I’ve been using in plain vanilla C and C++ style games. In fact, ActionScript’s interface seems pretty close to what I was building towards in my own game library, such as the display list, event listeners and even the method for storing local data.

This week I’m keen to get started on making games. My plan is to work through a chapter of the book a day if I can, which roughly equates to a game every evening. I’ll also try to do all the artwork too, as I need to get to grips with that aspect of Flash and Illustrator as well. Some days I’ll have to skip game work, and I’ll only have a few hours every evening, but I think it’ll be enough time with the book to help me.

Obviously only spending a few hours per game doesn’t lend itself to producing anything too spectacular; I expect some pretty bland games over the next week. But I’ll see what I can get done each day.

This evening I’ll get started on chapter three, which describes the process of making a tile matching game in Flash. We’ll see how it goes.

Permalink • Print • 2 Comments

Poll Results: Cake or Pie?

Although pie took an early lead, cake has sprung ahead in the last few days to narrowly take the win. I’m sure this is all very informative for… something. (I’m a cake guy myself; I’m quite fond of pie, but good quality cheesecake, fruitcake and carrot cake are hard to beat).

I’ve been meaning to put up a more meaningful poll, perhaps something asking about a game I’m making, ideas for the MAGIC contest, or possibly something regarding 4E6. However with the Four Elements contest still not started and my lack of brainstorming into MAGIC I’m forced to put up another more general poll.

This one is based on Richard Bartle’s card suit breakdown of playing styles in MUDs. It’s a good read for anyone interested in online game psychology. While I don’t play MMOs myself I am fascinated by the whole social dynamic of the phenomenon.

For those of you who don’t have the time to read the article, here’s a summary of the breakdown of playing styles:

  • Achievers or Diamonds (treasure-seekers) regard points-gathering and rising in levels as their main goal, with other activites being subserviant to this end.
  • Explorers or Spades (to dig up information) like to figure out how things work, look for interesting features within the game, and push the boundaries of the game.
  • Socialisers or Hearts (for empathy) are interested in other people and what they have to say.
  • Killers or Clubs (to beat people with) like to impose themselves on others, usually in the form of player-killing.
Permalink • Print

September 21, 2007


Today I’ve unexpectedly received the copy of Gary Rosenzweig’s ActionScript 3.0 Game Programming University I had on order from Amazon. I wasn’t expecting to receive this for another week or two. I’ve only had a chance to skim over the book this evening, but it looks like a very nice coverage of using both Flash CS3 and ActionScript 3.0 for games. It mainly teaches through example, so I’m going to shift from my original plan of hacking my way through making a game or two myself this weekend and work through the book.

So far my ActionScript learning has been mainly through reading the Adobe documents about the language, trying to a grasp of the fundamental concepts. I’m pretty impressed with the scope of ActionScript from what I’ve read. It does appear to be extremely object oriented, to the point where everything appears to be based on the object model - even functions, which can be given attributes and values just like class instances.

This weekend I’m hoping to have enough time to work my way through the first few games explained by Gary Rosenzweig. I’m debating whether I should download the graphic sets he’s got on his website or whether it will be a better exercise to make my own.

Permalink • Print • 2 Comments

September 18, 2007

Springing into ActionScript

My fingers on my left hand are now semi-operational. I can curl my middle finger about half way, enough to wrap it around large objects, but not enough to make a clenched fist. I can also write legibly now if I don’t put too much pressure on the pencil and I use large letters. It’s not healed enough for extended writing, but at least now I can jot things down as I work on a computer. I’m also speeding up with nine fingered typing, so that’s a bonus.

As I doubt my hand will be healed enough for fine pencil work for a while, I’ll dedicate this work to keyboard only tasks. From the perspective of game development, this means I’ll have to continue holding back learning Illustrator and Flash animation a while longer. I could just use geometric shapes with the mouse I suppose, but I’d prefer doing draft work with pencil (either real or digital), and I think it’s best to wait a bit before putting too much pressure on my swollen finger. Instead this week I’ll continue to get to grips with ActionScript 3.0.

More on Springing into ActionScript

Permalink • Print
Made with WordPress and an easy to customize WordPress theme • Trazoi Bounce Box skin by David Shaw