How to let your iOS App crash and have a bad Christmas

Integer Overflow
Having a bug in your code is never fun, but having a bug in your iOS game or app is even worse. You can’t just quickly fix it and hope nobody noticed. Your game has to go through Apple’s review process again, which takes time. Having a bug in your game just a couple of days before Christmas, can spoil your Christmas joy instantly. Apple is having a week off, meaning your bug will be in there for at least 2 weeks. The following Integer Overflow made me be angry at myself (and at Apple a bit). Don’t let it ruin your life.

Read More

Can’t touch this!

cant-touch-this
Handling touch events in SpriteKit is not as trivial as one might expect. Especially when two or more nodes are on top of each other. Which node will receive the touch event? In this article I will explain how touch events are handled and that this can lead to unexpected behaviour.

Read More

Outline text in SpriteKit

OutlinedText
I don’t know why, but there is no easy way to outline text in SpriteKit. You should expect SKLabelNode to have properties like strokeColor and strokeWidth. But as of this writing you don’t have a lot of options to customize SKLabelNode. Eventually Apple’s Core Text API, SKShapeNode and a little bit of magic did the trick.

Read More