You are previewing Unity iOS Game Development Beginner's Guide.
O'Reilly logo
Unity iOS Game Development Beginner's Guide

Book Description

Creating games for iOS can be fun and profitable. This guide takes you from first principles right through to building an actual game feature by feature and then monetizing it. No prior knowledge of Unity or iOS is required.

  • Dive straight into game development with no previous Unity or iOS experience

  • Work through the entire lifecycle of developing games for iOS

  • Add multiplayer, input controls, debugging, in app and micro payments to your game

  • Implement the different business models that will enable you to make money on iOS games

  • In Detail

    Would you like to create money making games for iOS? If so, Unity iOS Game Development Beginners Guideis for you. It will guide you through the entire creative process of designing a game through to making money from it.

    This book will teach you the secrets of building and monetizing games for the iOS platform using the latest version of Unity. The book is linear and progressive so every chapter builds upon the knowledge of the last. You will learn Unity and the iOS basics necessary to get started. You will design a game for the iOS. You will build that game feature by feature. Finally you will publish your game and add the features that will enable your game to generate revenue.

    You have never built anything using Unity or iOS so we will begin with the basics. We will then move onto the basic features of a game: scenes, AI, characters, accelerometer, and input methods. Once you have mastered this we will begin the creation of our game – a 3rd person perspective dungeon crawler game inspired by the arcade game called Gauntlet. You will bring AAA quality to the game by adding co-op multiplayer so that your friends can join in and participate in the game. You will also add occlusion culling and beastmap lighting. Next you will integrate the game with some 3rd party services for advertisements, micro transactions, and in app purchasing. You will also integrate with Game Center. Finally you will publish your game for the entire world to see.

    Table of Contents

    1. Unity iOS Game Development Beginner's Guide
      1. Table of Contents
      2. Unity iOS Game Development Beginner's Guide
      3. Credits
      4. About the Author
      5. About the Reviewers
      6. www.PacktPub.com
        1. Discounts
        2. Free eBooks
        3. Newsletters
        4. Code Downloads, Errata and Support
      7. PacktLib.PacktPub.com
      8. Preface
        1. What this book covers
        2. What you need for this book
        3. Who this book is for
        4. Conventions
        5. Reader feedback
        6. Customer support
          1. Downloading the example code
          2. Downloading the color images of this book
          3. Errata
          4. Piracy
          5. Questions
      9. 1. What is Unity and why should I care?
        1. Important preliminary points
        2. What is Unity?
        3. Getting a real application running on a device
        4. Time for action – Loading a project
          1. What just happened?
        5. Time for action – Select iPhone as a target platform
          1. What just happened?
        6. Time for action – Publishing to our device
          1. What just happened?
          2. Pop quiz – The fundamentals
        7. Summary
      10. 2. Getting Up and Running
        1. Welcome home
          1. Transform tools
          2. Transform Gizmo Toggles
          3. VCR Controls
          4. Layers drop-down
          5. Layout drop-down
          6. Project view
          7. Hierarchy view
          8. Scene view
          9. Game view
          10. Inspector
          11. Console view
          12. Profiler view
        2. Time for action – Creating a new layout
          1. What just happened?
        3. Time for action – Saving a new layout
          1. What just happened?
        4. Time for action – Deploying Unity Remote
          1. What just happened?
        5. Time for action – Testing our application using Unity Remote
          1. What just happened?
          2. Pop quiz – doing the thing
        6. Summary
      11. 3. Hello World
        1. Composing our first scene
        2. Start with the basics
        3. Time for action – Creating a scene
          1. What just happened?
        4. Time for action – Creating objects in a scene
          1. What just happened?
        5. Time for action – Let there be light
          1. What just happened?
        6. Time for action – Hello "World"
          1. What just happened?
        7. Time for action – Controling the camera
          1. What Just happened?
        8. Time for action – Deploying to the iOS device
          1. What just happened?
        9. Summary
      12. 4. Unity Concepts
        1. Basic concepts of Unity development
          1. Asset
        2. Time for action – Exporting asset packages
          1. What just happened?
        3. Time for action – Importing asset packages
          1. What just happened?
          2. Game Objects
          3. Components
        4. Time for action – Adding components to Game Objects
          1. What just happened?
          2. Transform
        5. Time for action – Positioning, Rotating, and Scaling a Game Object
          1. What just happened?
          2. Camera
            1. Camera properties
              1. Near Clip
              2. Far Clip
              3. Field of View (FOV)
            2. Camera projection types
              1. Orthographic projection
              2. Perspective projection
          3. Lights
            1. Directional light
            2. Point light
            3. Spot light
            4. Lightmapping
          4. Sound
            1. Audio listener
            2. Audio sources
            3. Audio clips
        6. Time for action – Adding audio clips
          1. What just happened?
          2. Scripts
            1. Editors
          3. Prefabs
        7. Time for action – Creating prefabs
          1. What just happened?
          2. Scene
        8. Summary
      13. 5. Scripting: Whose line is it anyway?
        1. Important preliminary points
        2. Unity Scripting Primer
          1. Oh no! You've got Mono!
          2. Common Language Infrastructure
          3. Boo- more than a ghost in mario
            1. What does a Boo script look like?
            2. Should I choose Boo?
          4. UnityScript/JavaScript – Relevant beyond the web
            1. What does a JavaScript script look like?
            2. Should I choose JavaScript?
          5. C# – The revenge of Microsoft
            1. What does a C# script look like?
            2. Should I choose C#?
        3. Time for action – Creating and organizing scripts
          1. What just happened?
          2. Attaching scripts to Game Objects
          3. Exposing variables in the Unity editor
          4. Key scripting methods
        4. iPhoneSettings
          1. Screen orientation
          2. Sleep mode
          3. Device information
        5. Time for action – Identifying the type of iOS
          1. Identify our device information
          2. Conditionally show splash screen
          3. Dismiss the splash screen
          4. What just happened?
          5. Location services
        6. Time for action – Changing state according to player location
          1. Start the location services on our device
          2. Expose variable to Unity editor
          3. Poll the device location information
          4. Get the weather for this location
          5. What just happened?
          6. Screen manipulation
        7. Time for action – Rotating the screen
          1. Identifying that the screen orientation has changed
          2. Updating player orientation
          3. What just happened?
        8. iPhoneUtils
          1. Playing movies
          2. Is my application genuine?
        9. Time for action – Yarr! There be pirates!
          1. What just happened?
        10. Accessing the camera
        11. Summary
      14. 6. Our Game: Battle Cry!
        1. Game Concept
          1. Story
          2. Interface
          3. Control
          4. Audio
        2. Time for action – Project setup
          1. What just happened?
        3. Time for action – Building a game world
          1. Unity Asset Store
          2. What just happened?
        4. Summary
      15. 7. Input: Let's Get Moving!
        1. Input Capabilities
          1. The technology of touch
            1. Resistive technology
            2. Capacitive technology
            3. Infrared technology
          2. Accelerometer
          3. Gyroscope
          4. Touch screen
          5. Accelerometer/Gyroscope
        2. Implementing Joysticks
        3. Time for action – Getting oriented
          1. What just Happened?
        4. Time for action – Implementing the joysticks
          1. What just happened?
        5. Moving around
        6. Time for action – Implementing the camera control
          1. What just happened?
        7. Time for action – Animating the player character
          1. Importing an animation
            1. Animation splitting
            2. Multiple files
          2. What just happened?
        8. Importing an animation
        9. Time for action – Importing from Mixamo
          1. What just happened?
        10. Driving our character
        11. Time for action – Driving our character
          1. What just happened?
        12. Time for action – Getting a driver's license with Root Motion Controller
          1. What just happened?
        13. Rotation via Accelerometer
        14. Time for action – Updating upon device tilt
          1. What just happened?
        15. Shaking the device to perform a healing action
        16. Time for action – Detecting a shake
          1. Physician heal thyself
          2. What just happened?
        17. Summary
      16. 8. Multimedia
        1. Important preliminary points
        2. Audio capabilities
          1. Playing sounds
        3. Time for action – Adding ambient sounds
          1. What just happened?
        4. Time for action – Adding sounds to actions
          1. What just happened?
          2. Playing music
        5. Time for action – The sound of music
          1. What just happened?
        6. Video capabilities
        7. Time for action – Playing embedded video
          1. What just happened?
        8. Time for action – Streaming video
          1. What just happened?
        9. Summary
      17. 9. User Interface
        1. Important preliminary points
        2. Translating the design
          1. Immediate mode game user interfaces
        3. Time for action – Creating the menu background
        4. What just happened?
          1. Putting the menu on the screen
        5. Time for action – Adding buttons to the GUI
          1. What just happened?
          2. A better way – UIToolkit
        6. Time for action – Prime31 UIToolkit
          1. What just happened?
        7. Summary
      18. 10. Gameplay Scripting
        1. Gunplay as gameplay
        2. Time for action – Readying the weapon
          1. What just happened?
          2. Firing projectiles
        3. Time for action – Adding a particle system
          1. What just happened?
        4. Let the animation drive
          1. Animation Events
        5. Time for action – Adding animation events
          1. What just happened?
        6. You are already dead
          1. World Particle Colliders
        7. Time for action – Detecting collisions
          1. What just happened?
        8. Playing with (rag) dolls
        9. Time for action – Attaching a rag doll
          1. What just happened?
        10. Summary
      19. 11. Debugging and Optimization
        1. Debugging
        2. Time for action – Using breakpoints
          1. What just happened?
        3. Time for action – Debugging the application
          1. What just happened?
        4. Time for action – Stepping through the game
          1. What just happened?
        5. Profiling
        6. Time for action – Fine tuning the application (Pro Versions)
          1. What just happened?
        7. Object pooling – Into the pool
        8. Time for action – Optimizing with the object pool
          1. What just happened?
        9. Unleash the beast
        10. Time for action – Generating Beast lightmaps
          1. What just happened?
        11. Summary
      20. 12. Commercialization: Make 'fat loot' from your Creation
        1. Business model generation
          1. Pure app sales
          2. Advertising
          3. In-App purchases
          4. Marketplace component
        2. Time for action – Readying your app for sale
          1. What just happened?
        3. Time for action – Adding iAds
          1. What just happened?
        4. In-App purchases
          1. Subscription types
          2. Delivery models
        5. Time for action – Adding In-App purchases
          1. What just happened?
        6. Time for action – Adding content to the Unity Asset Store
          1. What just happened?
        7. Measuring success with iTunes Connect
        8. Time for action – How is our game doing?
          1. What just happened?
        9. Summary
      21. A. Pop Quiz Answers
        1. Chapter 1
        2. Chapter 2
      22. Index