UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

What you learned

Although these projects shouldn’t have been too difficult for someone at your level, they definitely covered some important skills that you’ll come back to time and time again.

You also completed the technique project all about debugging. Although I covered the main techniques in that chapter, debugging isn’t really something that can be taught – it’s a skill you acquire over time with experience. As you progress, you’ll learn to recognize certain kinds of errors as ones you’ve solved before, so over time you get faster and spotting - and fixing – mistakes.

Some other things you learned in this milestone are:

  • MapKit, Apple’s incredible, free map framework that lets you add maps, satellite maps, route directions, and more.
  • How to use Timer to trigger a repeating method every few seconds. Remember to call invalidate() on your time when you want it to stop!
  • In SpriteKit, you learned to use the advanceSimulationTime() method to force a particle system to move forward a set number of seconds so that it looks like it has existed for a while.
  • We used the SKPhysicsBody(texture:) initializer to get pixel-perfect physics. This is computationally expensive, so you should use it only when strictly needed.
  • We used the linearDamping and angularDamping properties of SKPhysicsBody to force sprites to retain their speed and spin, rather than slowing down over time – project 23 was set in outer space, after all!
  • You learned how the assert() function lets you ensure your app’s state is exactly what you thought it was.
  • You set your first breakpoints, and even attached a condition to it. Trust me on this: you will use breakpoints thousands – if not hundreds of thousands! - of times in your Swift career, so this is a great skill to have under your belt.

BUILD THE ULTIMATE PORTFOLIO APP Most Swift tutorials help you solve one specific problem, but in my Ultimate Portfolio App series I show you how to get all the best practices into a single app: architecture, testing, performance, accessibility, localization, project organization, and so much more, all while building a SwiftUI app that works on iOS, macOS and watchOS.

Get it on Hacking with Swift+

Sponsor Hacking with Swift and reach the world's largest Swift community!

BUY OUR BOOKS
Buy Pro Swift Buy Pro SwiftUI Buy Swift Design Patterns Buy Testing Swift Buy Hacking with iOS Buy Swift Coding Challenges Buy Swift on Sundays Volume One Buy Server-Side Swift Buy Advanced iOS Volume One Buy Advanced iOS Volume Two Buy Advanced iOS Volume Three Buy Hacking with watchOS Buy Hacking with tvOS Buy Hacking with macOS Buy Dive Into SpriteKit Buy Swift in Sixty Seconds Buy Objective-C for Swift Developers Buy Beyond Code

Was this page useful? Let us know!

Average rating: 5.0/5

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.