Finally finished this test game intro comic thing. It is now complete and I can get on with some real work.
Moving from Delegates to Closures
One of the advantages of blogging about my work is that it makes me think carefully about what I’m doing. After finishing my post on my instruction system, I started reading more about closures which led me to reconsider some of the decisions I’d made.
Developing a Reusable Instruction System
I have been working on a library of basic components that is designed to work for many different types of game. It abstracts away platform-specific inputs, converting them into platform-agnostic interactions.
Taking this a step further, I have expanded this into an instruction system that takes advantage of Swift’s features to create an Instruction
struct. This struct uses pseudo-English formatting that makes adding actions to entities simple and easy to read:
Hobgoblin Movement of Peace
Dave Rapoza had a dream about hobgoblins fixing hatred in Twitter and called it the Hobgoblin Movement of Peace and Twitter responded by drawing a ton of hobgoblins.
Hit Testing and Event Propogation in SpriteKit
The docs for SKNode say that the hit test order is the reverse of the render order (i.e. hit testing works from the topmost node down), but this isn’t strictly true.
It implies that if you have two nodes overlapping and the top one is not participating in hit testing, then the next one down will get the event. Unfortunately, this isn’t what happens.
Swivel Turret Intro Comic Panel 2
Another panel from my intro animation to a mini-game that’s just there to test a development component library and so doesn’t need a title screen let alone an introductory comic animation.
Swivel Turret Intro Comic Panel
The test project I created for my SpriteKit components library is getting out of hand. Here is a panel from the introduction comic.
Yep, my example mini-game now has an introduction animated comic (if you were wondering why I haven’t released an actual game yet).
Day of the Tentacle
As always, spoilers! Day of the Tentacle was first released in 1993, so…
Day of the Tentacle was magical to 13-year-old me. The establishing shot of the mansion with its wild, bendy architecture was mesmerising. The thick bold lines and flat shading of Purple Tentacle as he sipped the ooze and set the story in motion was like nothing I had experienced up before in a video game.
Concept for SwivelTurret
I’m developing a library of reusable components. In order to make sure that they all work, I’m creating a couple of test games.
This is the design for the first: SwivelTurret, a Missile Command style game.
Handling Time Zones in iOS Apps
Time zones are one of those tricky programming problems. It can be difficult to understand what’s going on and maddening to debug, especially if you have customers all over the world.
The key is understanding that the Date()
struct in Foundation returns an absolute timestamp in UTC. UTC is a time standard (i.e. no countries adopt it as a time zone—they would use GMT which is a time zone but, for our purposes, is identical to UTC).