Today we’ll be completing our SpriteKit game, and I think you’ll be pleased by the end result. However to get to the end we’ll need to do a little mathematics: we need to convert between degrees and radians, and we need to calculator a vector from an angle and a speed.
I realize that for some reading this it has been a while since you studied mathematics at school, but if you stick with it I hope everything will become clear. As Ernest Rutherford once said, “all of physics is either impossible or trivial: it is impossible until you understand it, and then it becomes trivial.”
What’s more, I think the same is true of programming – today is day 95 of your learning journey, but if I’d talked to you about collision bitmasks,
@IBAction, and Core Graphics back when you first started learning you wouldn’t have understood a word of it. Now these things are slowly becoming second nature for you: bitmasks let us define what each of our objects are and what they should bounce off,
@IBAction marks a method being called when a user interface event happens, and Core Graphics lets us render images dynamically.
That’s another fantastic measure of how much progress you’ve made, and you’re not even done yet – keep going!
Today you have two topics to work through, and you’ll learn how to make texture atlases, how to simplify collision detection, how to transition between scenes, and more.
Need help? Tweet me @twostraws!
SPONSORED Catch bugs as soon as they happen and know exactly why a crash occurred. Instabug's SDK grabs all the logs they need to fix bugs, crashes and performance issues in minutes instead of days. Get screenshots, device details, network logs, repro steps, and tons of other critical insights needed to resolve issues and prioritize product backlogs straight from your dashboard. It only takes a minute to integrate!
Link copied to your pasteboard.