SKIP THE SHIPPING
Use code NOSHIP during checkout to save 40% on eligible eBooks, now through January 5. Shop now.
Register your product to gain access to bonus material or receive a coupon.
In just 24 sessions of one hour or less, Sams Teach Yourself Unity Game Development in 24 Hours will help you master the Unity 4 game engine at the heart of Temple Run and many other sizzling-hot mobile games! You’ll learn everything from the absolute basics through sophisticated game physics, animation, and mobile device deployment techniques. Every lesson builds on what you’ve already learned, giving you a rock-solid foundation for real-world success!
Step-by-step instructions carefully walk you through the most common Unity 4 game development tasks.
Learn how to…
Working with Models, Materials, and Textures in Unity Game Development
Download the sample pages (includes Chapter 3 and Index)
Preface xi
HOUR 1: Introduction to Unity 1
Installing Unity 1
Getting to Know the Unity Editor 5
Navigating the Unity Scene View 18
Summary 20
Q&A 20
Workshop 21
Exercise 21
HOUR 2: Game Objects 23
Dimensions and Coordinate Systems 23
Game Objects 27
Transforms 28
Summary 34
Q&A 34
Workshop 35
Exercise 35
HOUR 3: Models, Materials, and Textures 37
The Basics of Models 37
Textures, Shaders, and Materials 42
Summary 48
Q&A 48
Workshop 49
Exercise 49
HOUR 4: Terrain 51
Terrain Generation 51
Terrain Textures 59
Summary 62
Q&A 62
Workshop 63
Exercise 63
HOUR 5: Environments 65
Generating Trees and Grass 65
Environment Effects 72
Character Controllers 77
Summary 79
Q&A 79
Workshop 79
Exercise 80
HOUR 6: Lights and Cameras 81
Lights 81
Cameras 90
Layers 94
Summary 98
Q&A 98
Workshop 98
Exercise 99
HOUR 7: Game 1: Amazing Racer 101
Design 101
Creating the Game World 104
Gamification 106
Playtesting 113
Summary 114
Q&A 114
Workshop 114
Exercise 115
HOUR 8: Scripting Part 1 117
Scripts 118
Variables 125
Operators 127
Conditionals 130
Iteration 133
Summary 135
Q&A 135
Workshop 136
Exercise 136
HOUR 9: Scripting Part 2 137
Methods 137
Input 142
Accessing Local Components 147
Accessing Other Objects 148
Summary 152
Q&A 152
Workshop 152
Exercise 153
HOUR 10: Collision 155
Rigidbodies 155
Collision 157
Triggers 161
Raycasting 163
Summary 165
Q&A 165
Workshop 165
Exercise 166
HOUR 11: Game 2: Chaos Ball 167
Design 167
The Arena 169
Game Entities 173
The Control Objects 178
Improving the Game 182
Summary 183
Q&A 183
Workshop 183
Exercise 184
HOUR 12: Prefabs 185
Prefab Basics 185
Working with Prefabs 188
Instantiating Prefabs Through Code 194
Summary 194
Q&A 195
Workshop 195
Exercise 195
HOUR 13: Graphical User Interfaces 197
GUI Basics 197
GUI Controls 199
Customization 205
Summary 211
Q&A 211
Workshop 211
Exercise 212
HOUR 14: Character Controllers 213
The Character Controller 213
Scripting for Character Controllers 216
Building a Controller 219
Summary 225
Q&A 225
Workshop 225
Exercise 226
HOUR 15: Game 3: Captain Blaster 227
Design 227
The World 229
Controls 234
Improvements 242
Summary 242
Q&A 242
Workshop 243
Exercise 244
HOUR 16: Particle Systems 245
Particle Systems 245
Particle System Modules 247
The Curve Editor 257
Summary 259
Q&A 259
Workshop 259
Exercise 259
HOUR 17: Animations 261
Animation Basics 262
Preparing a Model for Animation 263
Applying Animations 269
Scripting Animations 272
Summary 273
Q&A 273
Workshop 274
Exercise 274
HOUR 18: Animators 277
Animator Basics 278
Creating an Animator 287
Scripting Animators 294
Summary 296
Q&A 296
Workshop 296
Exercise 296
HOUR 19: Game 4: Gauntlet Runner 297
Design 297
The World 298
The Entities 300
The Controls 307
Room for Improvement 314
Summary 315
Q&A 315
Workshop 315
Exercise 316
HOUR 20: Audio 317
Audio Basics 317
Audio Sources 319
Audio Scripting 324
Summary 326
Q&A 326
Workshop 327
Exercise 327
HOUR 21: Mobile Development 329
Preparing for Mobile 329
Accelerometers 333
Summary 338
Q&A 338
Workshop 338
Exercise 339
HOUR 22: Game Revisions 341
Amazing Racer 341
Chaos Ball 345
Captain Blaster 346
Gauntlet Runner 349
Summary 350
Q&A 351
Workshop 351
Exercise 351
HOUR 23: Polish and Deploy 353
Managing Scenes 353
Persisting Data and Objects 356
Unity Player Settings 359
Building Your Game 362
Summary 365
Q&A 365
Workshop 365
Exercise 366
HOUR 24: Wrap Up 367
Accomplishments 367
Where to Go from Here 370
Resources Available to You 371
Summary 371
Q&A 371
Workshop 372
Exercise 372
Index 373