Home   FAQs   New Arrivals   Specials   Pricing & Shipping   Location   Corporate Services   Why Choose Bookware?  
 Search:   
Call our store: 9955 5567 (from within Sydney) or 1800 734 567 (from outside Sydney)
 View Cart   Check Out   
 
Browse by Subject
 TAFE Accounting
 TAFE I.T./Computing
 TAFE - Other
I.T
 .NET
 Windows 8
 Adobe CS6
 Cisco
 CCNA 2012
 CCNP 2012
 Java
 VB
 ASP
 Web Design
 E-Commerce
 Project Management
 ITIL
 Macintosh
 Mobile Devices
 Linux
 Windows Server 2012
 SQL Server 2012
 SAP
Certification
 MCITP
 MCTS
Economics and Business
 Accounting
 Business Information Systems
 Economics
 Finance
 Management
 Marketing
 TAX
 Human Resources
Academic
 Law
 Nursing
 Medical
 Psychology
 Engineering

Learning iOS Game Programming: A Hands-On Guide to Building Your First iPhone Game

by: Michael Daley

Notify me when in stock

On-line Price: $29.61 (includes GST)

Paperback package 448

13%Off Retail Price

You save: $5.00

Usually ships within 4 - 5 business days.
_____________________
N.Sydney : On Order (reserve your copy)

Retail Price: $34.61

Publisher: ,01.10.10

Category: Iphone and Ipod Level:

ISBN: 0321699424
ISBN13: 9780321699428

Add to Shopping Cart

Features and Benefits

top


The complete, practical, hands-on guide to building 2D games for iPhone and iPod touch - no game programming experience necessary!

¿
# The only beginner's iPhone game development book: reaches the fastest-growing part of today's fastest-growing software market
# Leads readers step-by-step through building a complete game
# Covers animation, fonts, tile maps, particle systems, sound effects, music, collision detection, and more



Table of Contents

top


Preface


    xxi

1


Game Design


    1

The Game That Started It All (For Me)


    3

So, What's the Big Idea?


    4



A Game That Fits with the iPhone


    4



The Storyline


    5



What's in a Name?


    5



The Game's Objective


    6

Game Play Components


    7



Time


    7



Lives


    7



Health


    8



Objects


    8



Doors


    9



Weapons


    10



Entities


    10



Player


    11

Summary


    11

2


The Three Ts: Terminology, Technology, and Tools


    13

Terminology


    14



Sprite


    14



Sprite Sheet


    16



Animation


    18



Bitmap Fonts


    19



Tile Maps


    20



Particle System


    21

Collision Detection


    22



Artificial Intelligence (AI)


    23



Game Loop


    24

Technology


    26



Objective-C


    26



Cocoa Touch


    27



OpenGL ES


    27



OpenAL


    30

Tools


    31



The iPhone SDK


    32

Summary


    38

3


The Journey Begins


    39

Creating the Project in Xcode


    39

Running the Project


    42

Under the Hood


    43

Application Delegate


    43



Examining the Header File


    44



Examining the Implementation File


    46

EAGLView


    49



EAGLView.h


    49



EAGLView.m


    50

ES1Renderer


    58



Examining ES1Renderer.h


    58



Examining ES1Renderer.m


    59



Creating the Framebuffer and Renderbuffer


    60



Defining the Color Values


    66



Positioning


    67

How OpenGL Works


    68



Applying Transformations on the Model


    69



Rendering to the Screen


    70

Summary


    72

4


The Game Loop


    73

Timing Is Everything


    73

Collision Detection


    74

The Game Loop


    75



Frame-Based


    75



Time-Based, Fixed Interval


    77

Getting Started


    78



Inside the EAGLView Class


    79



Inside the EAGLView.m File


    79



ES1Renderer Class


    82



Configuring the View Port


    85

Game Scenes and the Game Controller


    86



Creating the Game Controller


    87



The GameController Class


    87



Creating the Singleton


    89



Inside GameController.m


    89



AbstractScene Class


    92



GameScene Class


    93

Summary


    95

Exercises


    95

5


Image Rendering


    97

Introduction to Rendering


    97

Rendering a Quad


    98

Texture Mapping


    101



Texture Coordinates


      101

Interleaved Vertex Arrays


    104

Structures


    106

Image Rendering Classes


    107



Texture2D Class


    108



TextureManager Class


    116



ImageRenderManager Class


    119

The Image Class


    126

I

nitialization


    126



Retrieving a Sub-Image


    129



Duplicate an Image


    130



Rendering an Image


    130



Getters and Setters


    134

Summary


    134

Exercise


    135

6


Sprite Sheets


    137

Introduction to Sprite Sheets


    137



Simple Sprite Sheet


    138



Complex Sprite Sheets


    139

Using Zwoptex


    141

The SpriteSheet Class


    142



Initialization


    143



Retrieving Sprites


    146

PackedSpriteSheet Class


    147



Initialization


    147



Parsing the Control File


    148



Retrieving a Sprite


    149

Summary


    150

Exercise


    151

7


Animation


    153

Animation Chapter Project


    153

Introduction to Animation


    154



Frames


    154



State


    w155



Type


    155



Direction


    155



Bounce Frame


    155

Animation Class


    156



Initialization


    156



Adding Frames


    157



Animation Updates


    158



Animation Rendering


    160



Finishing Things Off


    161

Summary


    163

Exercise


    163

8


Bitmap Fonts


    165

Bitmap Font Project


    165

Introduction to Bitmap Fonts


    166

Creating the Bitmap Font Sprite Sheet


    167

The BitmapFont Class


    170



Header File


    170

What's with the C?


    171



Initializer


    171



Parsing the Control File


    172

Rendering Text


    176



Rendering Justified Text


    178



Text Width and Height


    180



Deallocation


    181

Summary


  181

Exercise


    182

9


Tile Maps


    183

Getting Started with the Tile Map Project


    183

Introduction to Tile Maps


    184

Tile Map Editor


    186



Tile Palette


    188



Layers


    188

Creating a Tile Map


    189



Create a New Tile Set


    190



Creating Map Layers


    191



Creating Object Layers


    191



Drawing the Map


    192



Placing Objects


  192

Understanding the Tiled Configuration File


    193



Map Element


    193



Tileset Element


    193



Layer Element


    194



Object Group Element


    195

Tile Map Classes


    196



Layer Class


    196



TileSet Class


    202



TiledMap Class


    204



Initialization


    205



Parsing a Map File


  207



Creating the Layer Images


    216



Rendering a Layer


    218



Getting Tile Informaiton


    220

Summary


    220

Exercise


    221

10


The Particle Emitter


    223

Particle Emitter Project


    224



Introduction to Particle Systems


    225



Particle System Parameters


    226

Life Cycle of a Particle


    227



A Particle Is Born


    227



A Particle Lives


    228



A Particle Dies


    229



A Particle Is Reborn


    229

Particle Emitter Configuration


    230

Particle Emitter Classes


    231



TBXMLParticleAdditions Class


    231



ParticleEmitter Class


    233

Have a Play


    247

Summary


    248

11 Sound


    249

Sound Project


    249

Introduction to Sound on the iPhone


    250



Audio Sessions


    250



Playing Music


    252



Playing Sound Effects


    252



Creating Sound Effects


    254



Stereo Versus Mono


    256

Sound Manager Classes


    256



SoundManager Class


    257

Sound Effect Management


    273



Loading Sound Effects


    274



Playing Sound Effects


    276



Stopping Sound Effects


    279



Setting Sound Effect and Listener Position


    281

Handling Sound Interruptions


    281

Summary


    284

12


User Input


    285

User Input Project


    285

Introduction to User Input


    287



Touch Events


    287

Processing Touch Events


  289



The touchesBegan Phase


    290



The touchesMoved Phase


    292



The touchesEnded Phase


    294

Processing Taps


    294

Accelerometer Events


    296

Summary


    298

13


The Game Interface


    299

Game Interface Project


    299

OpenGL ES Interface


    300



Rendering the Interface


    301



Defining Button Bounds


    304



Handling Touches


    304



Handling Transitions


    308



OpenGL ES Orientation


    308

UIKit Interfaces


    312



Creating the Interface


    312



Wiring Up the Interface


    315



UIKit Orientation


    318



Showing and Hiding a UIKit Interface


    320

Summary


    323

14


Game Objects and Entities


    325

Game Objects and Entities Project


    325

Game Objects


    326



AbstractObject Class


    327



EnergyObject Class


    329

Game Entities


    338



AbstractEntity Class


    339



Artificial Intelligence


    341



Player Entity Class


    343

Saving a Game Object or Entity


    352

Summary


    355

15


Collision Detection


    357

Introduction to Collision Detection


    357



Collision Pruning


    358

Frame-Based Versus Time-Based


    359

Axis-Aligned Bounding Boxes


    360

Detecting Collisions


    361

Collision Map


    362

Entity-to-Map Collision Detection


    365

Entity-to-Entity Collision Detection


    367

Summary


    368

16


Putting It All Together


    369

The "Camera"


    369

Saving the Game State and Settings


    371



Saving Game State


    371



Loading Game State


    373



Saving Game Settings


    375



Loading Game Settings


    376

Saving High Scores


    377



Adding a Score


    379



Saving High Scores


    380



Loading High Scores


    381

Performance and Tuning


    382



Using Instruments


    383



Leaks Instrument


    384



Using the OpenGL ES Instrument


    387



Compiling for Thumb


    389

Beta Testing


    390



Multiple Device Types


    391



Feedback


    392

Summary


    392

Index


    395



About the Authors

top


By day, Michael Daley works for the largest enterprise software company in the world supporting large corporate customers in communications. By night, Michael has taken on the task of learning how to build games for the iPhone. Michael started writing adventure games in BASIC on a Sinclair Spectrum 48k and progressed onto the Commodore 64 and the Amiga A500. Never having lost a passion for game programming, Michael got inspired to learn Objective-C when the iPhone came out, and he set out to learn how to build games for the iPhone.

Having written many games for his children over the years, the launch of the iPhone inspired him to create games for the platform that would be available to more than his children. Michael has a passion for learning new technologies and how to apply them. He's a true Apple fan, spending far too much time and money on the latest Apple equipment.