SpriteKit Smooth Rotation

Making a sprite rotate towards a certain direction is very easy in SpriteKit. In this short tutorial I will show how to make a sprite rotate smoothly towards a point that you touch on the screen. In addition the sprite will move towards the location. This tutorial is written for Swift 3. Getting Started Launch […]

Setting A Restore Point For A Character In SpriteKit

If you are making a game with long or difficult levels, it can be a good idea to have your player spawn at a location other than the start of the level if the game is lost. It may be better for gameplay or to provide an incentive to continue with difficult levels. Here’s one […]

Swift 3 Access Levels

Swift 3 now provides five access levels for code entities. The five levels are shown below from least to most restrictive. OPEN Open access allows entities to be accessed from any source code within your module and also external modules. PUBLIC The same as open but restricts subclassing to your module. INTERNAL This is the […]

SpriteKit Physics Memory Leak

During testing I discovered my game was leaking a small amount of memory each second. Using Instruments I discovered the problem seemed to be connected to PhysicsKit. In GameViewController I had enabled showPhysics to check the physics bodies of the nodes. This was causing the memory. It’s not a big problem as this would not […]

Subclassing UIButton in Swift Tutorial

This tutorial shows you how to add more functionality to UIButtons by subclassing. It demonstrates the use of enumerations to make each button a different type and extensions to give the subclassed UIButton more functionality. In this tutorial we will create a very basic interface which consists mostly of a grid of UIButton’s. However, our […]

Simple Slider Tutorial Using Swift

This tutorial shows you how to make a simple but effective slider view for iOS. Although there are a lot of steps here, the actual project is really easy to understand and you can download the completed project if you wish. This tutorial uses Swift and focuses on just getting the slider on the screen […]

Adaptive UITableView Cells

This tutorial will show you the method I use to make an UITableViewCell with an adaptive height. The article assumes you have a little experience with adaptive layout, Swift and custom classes. Here’s the process I use. You can also download a copy of the project which contains the example used here as well as […]