About the Author
Stephen Haney began his programming journey at the age of 8 on a dusty, ancient laptop using BASIC. He has been fascinated with building software and games ever since. Now well versed in multiple languages, he most enjoys programming as a creative outlet. He believes that indie game development is an art form: an amazing combination of visual, auditory, and psychological challenges, rewarding to both the player and the creator.
He enjoyed writing this book and sincerely hopes that it directly furthers your career or hobby.
Thank you to my beautiful girlfriend, Kayla, for her patience and advice.
About the Reviewers
Antonio Bello is a veteran software developer, who started writing code when memory was measured in bytes instead of gigabytes and storage was an optional add-on. Over his professional career, he has worked with several languages and technologies, in many cases, following a "learning by using" approach.
Today, he loves developing iOS Apps and their respective backends, favoring Swift over Objective C but loving both languages.
Vladimir Pouzanov is a systems engineer and an embedded enthusiast. He has spent countless hours hacking different mobile hardware, porting Linux to various devices on which it was not supposed to be run, and toying outside the iOS sandbox. He has been a professional iOS consultant and has been developing applications based on iOS since the first Apple iPhones were available. Later on, he switched his professional interest to systems engineering and cloud computing, but he still keeps a close eye on the mobile and embedded world.
I'd like to thank my wife for her amazing support while I was working on the review, sharing my attention between her, our daughter, and the book.
Kevin Smith is a founder and mobile developer. He released his first iPhone App in 2009. After the success of his first few apps, he founded App Press to help others build mobile apps. Through App Press, he has worked on and released countless award-winning iOS and Android apps.
Anil Varghese is a software engineer from Kerala, India, with extensive experience in iOS application development. He constantly strives to learn new technologies and better and faster ways of solving problems. He always finds time to help his fellow programmers and is an active member of developer communities, such as Stack Overflow.
You can reach him at <.
www.PacktPub.com
Support files, eBooks, discount offers, and more
For support files and downloads related to your book, please visit www.PacktPub.com.
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at > for more details.
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.
https://www2.packtpub.com/books/subscription/packtlib
Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can search, access, and readPackt's entire library of books.
Why subscribe?
- Fully searchable across every book published by Packt
- Copy and paste, print, and bookmark content
- On demand and accessible via a web browser
Free access for Packt account holders
If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view 9 entirely free books. Simply use your login credentials for immediate access.
Preface
There has never been a better time to be a game developer. The App Store provides a unique opportunity to distribute your ideas to a massive audience. Now, Swift has arrived to bolster our toolkit and provide a smoother development experience. Swift is new, but is already hailed as an excellent, well-designed language. Whether you are new to game development or looking to add to your expertise, I think you will enjoy making games with Swift.
My goal in writing this book is to share a fundamental knowledge of Swift and SpriteKit. We will work through a complete example game so that you learn every step of the Swift development process. Once you finish this text, you will be comfortable designing and publishing your own game ideas to the App Store, from start to finish.
Please reach out with any questions and share your game creations:
E-mail: <>
Twitter: @sdothaney
The first chapter explores some of Swift's best features. Let's get started!
What this book covers
, Designing Games with Swift , introduces you to best features on Swift, helps you set up your development environment, and launches your first SpriteKit project.
, Sprites, Camera, Actions! , teaches you the basics of drawing and animating with Swift. You will draw sprites, import textures into your project, and center the camera on the main character.
, Mix in the Physics , covers the physics simulation fundamentals: physics bodies, impulses, forces, gravity, collisions, and more.
, Adding Controls , explores various methods of mobile game controls: device tilt and touch input. We will also improve the camera and core gameplay of our example game.