Wrap up
Wrap up êŽë š
You've just finished a massive project, and regardless of how much you have learned you deserve kudos for all your patience. This project required you to follow several long steps before you could see your code run. I hope it was worth it, and I hope in retrospect that you can see why all the code was needed.
Along the way, you've learned all about SKShapeNode
, AVAudioPlayer
, physics speed, CaseIterable
, removeFirst()
, action groups, and more, so you're several steps closer to your goal of being an experienced Swift developer. Well done!
Review what you learned
Anyone can sit through a tutorial, but it takes actual work to remember what was taught. Itâs my job to make sure you take as much from these tutorials as possible, so Iâve prepared a short review to help you check your learning.
Challenge
One of the best ways to learn is to write your own code as often as possible, so here are three ways you should try your new knowledge to make sure you fully understand whatâs going on:
- Try removing the magic numbers in the
createEnemy()
method. Instead, define them as constant properties of your class, giving them useful names. - Create a new, fast-moving type of enemy that awards the player bonus points if they hit it.
- Add a âGame overâ sprite node to the game scene when the player loses all their lives.