characters, 54
cameras. See cameras
converting, 298
homogenous coordinates, 68
model spaces, 67
transforming 4D vectors by matrices, 69
colors, 76
Phong reflection models, 82-83
object representations, 91
overview of, 66
polygons, 66
5.1 surround sound systems, 118
AAA titles, 4
absolute coordinates, 218, 298
abstract syntax tree. See AST
accounts, GitHub, 311
adding
breakpoint conditions, 307
addition
matrices, 58
addresses
ping, 245
protocols. See protocols
admissible heuristics, 184-185
advantages
game state cheats, 256
hosts, 253
state-based behaviors, 192-198
strategies, 298
types of, 180
AIController class, 195
aiming reticules, 211-212, 298
algebra
matrices, 58
addition/subtraction, 58
inverse, 60
scalar multiplication, 58
transforming 3D vectors, 60-61
transposes, 60
dot products, 48
rotating 2D characters, 54
scalar multiplication, 47
algorithms
Bresenham’s line-drawing, 66
culling, 88
instantaneous collision detection, 141, 295
occlusion, 88
painter’s, 23, 85-86, 289, 292
ambient components, 82
analog
analysis
code
lexical, 230
Angry Birds Space, 33
angular mechanics, 153
AnimatedSprite class, 26
AnimFrameData structure, 26
AppDelegate class, 263
application debuggers, 304
call stack windows, 307
data breakpoints, 308
applying
multiple transforms, 71
apps, mobile phones, 33
arbitrary convex polygons, 133
arbitrary points, planes, 295
arcade versions, 6
areas, nodes, 296
arrows, waypoint, 208-211, 298
artifacts, 66
Artificial Intelligence and Interactive Digital Entertainment (AIIDE) conference, 198
artificial intelligence. See AI
ASCII characters, 299
aspect ratios, 163
Assassins Creed: Revelations, 4
AST (abstract syntax tree), 232
attacks, man-in-the-middle, 256-257, 301
attitudes, 108
Audacity, 112
audio
3D sound, 115
falloff, 118
obstruction, 123
sound
occlusion, 123
source data, 112
augmented reality games, 293
automating edges, 182
axis-aligned bounding boxes, 132, 135-136, 295
back face culling, 79
backgrounds, parallax scrolling, 32-34
Backus-Naur Form. See BNF
basic sounds, 112
source data, 112
basis vectors, 57
behaviors, state-based, 192-198
finite state machines, 193-194
state machines, implementing, 195-196
bidirectional reflectance distribution function (BRDF), 82
binary formats, 236
binary spatial partitioning. See BSP
binding, native, 227
BioShock, 163
BioShock: Infinite, 221
bit depth, 76
bitfield, 250
BNF (Backus-Naur Form), 232
bounding spheres, 131
branches, 310
BRDF (bidirectional reflectance distribution function), 82
breakpoints
conditions, 307
data, 308
Bresenham’s line-drawing algorithm, 66
BSP (binary spatial partitioning), 88, 148
buffers
double buffering, 22
bugs, issue tracking, 313
Bugzilla, 313
builds, Release, 306
bullet through paper problem, 141
bullet time, 10
Burnout, 160
Bushnell, Nolan, 2
calculating
force, 151
frames, 27
points, 177
Call of Duty, 217
call stack windows, 307
cameras, 158
cutscene, 161
_Defense, 279
fixed, 158
non-player controlled, 158
perspective projections, 161-163
positioning, 296
capsules, 133
Cartesian coordinate spaces, 67
case studies, World of Warcraft, 239-241
cathode ray tubes. See CRTs
CCD (continuous collision detection), 141
central processing units. See CPUs
ChangeAnim function, 27
change of basis matrix, 57
channels, LFE, 118
characters
2D, rotating, 54
ASCII, 299
NPCs, 180
cheats, 255
game state, 256
man-in-the-middle attacks, 256-257
Chrono Trigger, 3
Civilization, 181
C language, 2
classes
AIController, 195
AnimatedSprite, 26
AppDelegate, 263
encapsulation, 271
Enemy, 265
Game, 274
GameplayScene, 263
GameState, 275
MainMenuLayer, 263
Pathfinder, 278
Projectile, 265
ScrollingLayer, 264
Ship, 265
Singleton, 274
Timer, 278
clicks, mouse, 100
clients, 300
diff/merging tools, 312
predication, 252
closed sets, 186
cocos2d, 262
code. See also languages
analysis
debuggers, 304
call stack windows, 307
data breakpoints, 308
duplication, 293
letter key, 298
scripting languages, 224
Lua, 227
visual scripting systems, 229
source control, 310. See also source control
coefficient of restitution, 147
collisions
detection, 134
axis-aligned bounding box intersection, 135-136
line segment versus plane intersection, 136-137
line segment versus triangle intersection, 138-139
sphere intersection, 134
sphere versus plane intersection, 140
swept sphere intersection, 141-145
colors, 76
resolution, 20
column-major vectors, 61
components
ambient, 82
diffuse, 82
specular, 83
w-components, 68
compressors, 120
Computer Space, 2
conditions
breakpoints, adding, 307
hit count, 307
conditions, 307
data, 308
_Defense, 273
source control, 309
SVN, 309
conjugate of quaternions, 90
connections
ConstructPlan function, 199
continuous collision detection. See CCD
control
flow
game loops, 5
source, 309
SVN, 309
converting
3D coordinates, 298
coordinate systems, 56
vectors, 46
convexes
hulls, 133
3D, converting, 298
model spaces, 67
homogenous coordinates, 68
textures, 77
UV, 78
CPUs (central processing units), 7
Crane, David, 3
crashes, issue tracking, 313
Crazy Taxi, 208
CRTs (cathode ray tubes), 20-21
Crysis, 2
culling
algorithms, 88
back face, 79
cycles, development, 2
Dabney, Ted, 2
data breakpoints, 308
data formats, 235
binary, 236
JSON, 238
XML, 237
dead zones, 97
debuggers, 304
call stack windows, 307
dedicated servers, 253
_Defense, 270
MonoGame, 273
XNA, 272
depth
bit, 76
buffers, 86
design, 196-198. See also configuring
Design Patterns, 196
detection, collision, 134
axis-aligned bounding box intersection, 135-136
line segments
versus plane intersection, 136-137
versus triangle intersection, 138-139
spheres
intersection, 134
versus plane intersection, 140
swept sphere intersection, 141-145
development, cycles, 2
devices
digital, 292
event-based input systems, 99-104
input, 94
mobile input, 105
accelerometers/gyroscopes, 106-108
Diablo III, 74
Diablo, 38
diamond problem, 14
diff tools, 312
diffuse component, 82
digital devices, 292
digital signal processing. See DSP
Dijkstra’s algorithm, 192, 297
dimensions
matrices
inverse, 60
scalar multiplication, 58
transforming 3D vectors, 60-61
transposes, 60
dot products, 48
rotating 2D characters, 54
scalar multiplication, 47
distance
Euclidean, 185
Manhattan, 184
documentation, issue tracking, 313
Doppler shifts, 120
dot products, vectors, 48
double buffering, 22
doubly linked lists, 289
drawing
vectors, 43
dropping frames, 12
DSP (digital signal processing), 119-122, 294
duplication of code, 293
echo packets, 245
effects
electron guns, 289
elements, HUD, 207
encapsulation, 271
encryption, 257
Enemy class, 265
enumerations, keycode, 95
equality, vectors, 43
equations, parametric, 295
errors, operator precedence, 226
Euclidean distance, 185
event-based input systems, 99-104
events, 293
evolution of video game programming, 2
NES/SNES era (1985-1995), 3
Playstation/Playstation 2 era (1995-2005), 3
PS3/Wii/Xbox 360 era (2005-2013), 4
exercises
experience, UX, 221
expressions, regular, 231, 299
Extensible Markup Language. See XML
falloff, 118
Fallout, 38
field of view. See FOV
fields, vectors, 42
audio
source data, 112
images, 28
source control, 309
SVN, 309
text-based, 235
XML, 237
filtering
low-pass filters, 120
finite state machines, 193-194
Fire script function, 101
first-person cameras, 159-160, 170
fixed cameras, 158
flat shading, 83
flow control, game loops, 5
formatting. See also design
binary files, 300
data formats, 235
binary, 236
JSON, 238
XML, 237
_Defense, 273
side scrollers, 260
cocos2d, 262
Objective-C language, 261
tower defense games, 270
MonoGame, 273
XNA, 272
four-way scrolling, 34
FOV (field of view), 76, 161-162
FPS (frames per second), 5, 289
frame buffers, 86
FrameData, 26
frames
calculating, 27
dropping, 12
limiting, 12
rates, 288
frames per second. See FPS
frameworks
cocos2d, 262
MonoGame, 273
XNA, 272
Fresnel acoustic diffraction, 123
Full Spectrum Warrior, 4
ChangeAnim, 27
ConstructPlan, 199
Fire script, 101
getter/setter, 271
Initialize, 27
LoadLevel, 277
parametric, 129
SetState, 196
storing, 293
Update, 196
UpdateAnim, 27
UpdateInput, 101
Game class, 274
GameplayScene class, 263
games
AI
state-based behaviors, 192-198
types of, 180
augmented reality, 293
cameras. See cameras
linear algebra for
networked, 244. See also networked games
GameState class, 275
generating
outputs, 5
geometry, collision, 130
arbitrary convex polygons, 133
axis-aligned bounding boxes, 132
bounding spheres, 131
capsules, 133
lists, 134
oriented bounding boxes, 132
getter functions, 271
ghosts in Pac Man, 194
God of War, 158
GPS data, 108
GPUs (graphics processing units), 66
Grand Theft Auto III, 3
Grand Theft Auto IV, 4
graphical artifacts, 66
graphics
2D. See 2D graphics
3D. See 3D graphics
_Defense, 281
rendering, 7
graphics processing units. See GPUs
graphs, representing search spaces, 181-183
Grassmann products, 90
greedy best-first algorithms, 185-189
grids, matrices, 58
Grim Fandango, 227
guitar controllers, 94
Halo, 255
handedness of coordinate systems, 52
hard-coding UI text, 298
Havok, 153
Havok Physics, 4
heads-up display. See HUD elements
heads (vectors), 43
head-tracking devices, 94
height, aspect ratios, 163
history
of video game programming, 2
NES/SNES era (1985-1995), 3
Playstation/Playstation 2 era (1995-2005), 3
PS3/Wii/Xbox 360 era (2005-2013), 4
source control, 309
SVN, 309
hit count conditions, 307
homogenous coordinates, 68
hosts, advantages, 253
HTTP (Hypertext Transfer Protocol), 257
HTTPS (Secure HTTP), 257
HUD (heads-up display) elements, 207
ICMP (Internet Control Messaging Protocol), 245-246, 300
identifiers, tokenization, 230
if statements, 31
image files, 28
implementing
cutscene, 161
fixed, 158
non-player controlled, 158
perspective projections, 161-163
impulse-driven systems, 120
infinite scrolling, 32
information cheats, 255-256, 301
Initialize function, 27
_Defense, 280
devices, 94
mobile, 105
accelerometers/gyroscopes, 106-108
inputs, processing, 5
instantaneous collision detection algorithms, 141, 295
integration
methods, 153
numeric methods, 295
Internet Control Messaging Protocol. See ICMP
Internet Protocol. See IP
intersections
axis-aligned bounding boxes, 135-136
inverse matrices, 60
IP (Internet Protocol), 244-245, 300
isometric views, 290
issue tracking, 313
Iwatani, Toru, 194
JavaScript Object Notation. See JSON
Jobs, Steve, 261
JSON (JavaScript Object Notation), 113, 238
KeyState value, 96
keywords, tokenization, 230
Kinect, 94
Kismet, 229
Lammers, Susan, 194
C, 2
Objective-C, 261
Lua, 227
visual scripting systems, 229
XML, 237
Last of Us, The, 2
latency, 245
squared, 46
lerp. See linear interpolation
letter key codes, 298
lexical analysis, 230
LFE (low-frequency effects) channels, 118
libraries, XNA game, 272
colors, 76
per pixel, 84
Phong reflection models, 82-83
limiting frames, 12
linear algebra
dot products, 48
rotating 2D characters, 54
scalar multiplication, 47
linear mechanics, 149
line segments, 129-130, 136-139
lists of collision geometries, 134
LoadLevel function, 277
local lighting models, 82
lockstep models, 301
logic as function of delta time, 10-12
look-at matrices, 72
Lord of the Rings: Conquest, 57, 117
loss, packets, 247
low-frequency effects. See LFE channels
low-pass filters, 120
machines, state
macro strategies, 198
magnitude, 46. See also length
MainMenuLayer class, 263
Manhattan distance, 184
man-in-the-middle attacks, 256-257, 301
textures, 77
mass, 149
math
matrices, 58
3D vectors, transforming, 60-61
4D vectors, transforming, 69
addition/subtraction, 58
inverse, 60
look-at, 72
rotation, 70
scalar multiplication, 58
scale, 69
transform, 69
translation, 70
transposes, 60
maximum transmission units. See MTUs
Max Payne, 10
mechanics
angular, 153
linear, 149
memory, 2
menus, 204
merging tools, 312
meshes, 66
messages, Objective-C, 261
methods. See also functions
integration, 153
numeric integration, 295
partitioning, 148
metrics, 313
micro strategies, 198
middleware, 4, 153-154, 221, 288
mipmapping, 28
mobile input, 105
accelerometers/gyroscopes, 106-108
mobile phones, apps, 33
models
local lighting, 82
lockstep, 301
spaces, 67
MonoGame, 273
Moon Patrol, 33
Mountain Lion, 260
movement, physics, 148
angular mechanics, 153
calculating force, 151
Euler/semi-implicit Euler integration, 151-152
integration methods, 153
linear mechanics, 149
variable time steps, 150
velocity Verlet integration, 152-153
MTUs (maximum transmission units), 247
multicore consoles, 9
multicore CPUs, 7. See also CPUs
multiplayer support, 5
multiple resolution support, 218-219
multiple transforms, applying, 71
multiplication
order of, 291
vectors, 47
multi-touch, 105
Namco, 6
native binding, 227
navigating
accelerometers/gyroscopes, 106-108
HUD elements, 207
menus, 204
near planes, 75
NES (Nintendo Entertainment System), 3
protocols, 244
NeXT, 261
nodes, 181
areas, 296
path, 182
scene, 262
non-player characters. See NPCs
non-player controlled cameras, 158
normalization, 46
normal to planes, 51
NPCs (non-player characters), 180
numbers
matrices, 58
sequence, 250
numeric integration methods, 295
Objective-C language, 261
objects, 13
categories of, 289
polygons, 66
representations, 91
static, 13
types of, 13
obstruction, sound, 123
occlusion
algorithms, 88
octets, 245
octrees, 148
Oculus Rift, 108
online multiplayer support, 5
OpenAL, 112
open sets, 186
operators
precedence errors, 226
tokenization, 230
optimizing collisions, 147-148
order
of multiplication, 291
winding, 78
oriented bounding boxes, 132
orthographic projections, 292
overdraw, 85
packets, 244
echo, 245
ICMP, 246
loss, 247
UDP, 249
painter’s algorithm, 23, 85-86, 289, 292
parallelogram rule, 44
parametric equations, 295
parametric functions, 129
partitioning, 148
Pathfinder class, 278
path nodes, 182
patterns
state design, 297
performance, TCP, 248
per pixel lighting, 84
perspective, projections, 74, 161-163
Phong
shading, 84
collision detection, 134
axis-aligned bounding box intersection, 135-136
line segment versus plane intersection, 136-137
line segment versus triangle intersection, 138-139
sphere intersection, 134
sphere versus plane intersection, 140
swept sphere intersection, 141-145
_Defense, 280
planes, 128
PhysX, 153
ping, 245
Pitfall!, 3
planes, 128
arbitrary points, 295
near, 75
Playstation/Playstation 2 era (1995-2005), 3
points
calculating, 177
light, 81
arbitrary convex, 133
Pong, 192
positioning
cameras, 296
vectors, 42
precedence, operator errors, 226
prediction, clients, 252
Prince of Persia: The Sands of Time, 10
processing
CPUs. See CPUs
inputs, 5
processors, history of, 2
products
dot, 48
Grassmann, 90
Programmers at Work, 194
programming
3D graphics
homogenous coordinates, 68
overview of, 66
polygons, 66
transforming 4D vectors by matrices, 69
game loops, 5
objects, 13
Projectile class, 265
projections
_Defense, 279
orthographic, 292
protocols, 244
HTTP, 257
HTTPS, 257
PS3 era (2005-2013), 4
Python, 225
quadtrees, 148
QuakeC, 225
radii squared, 134
RAM (random access memory), 2
rasterization, software, 66
rates, frames, 288
ratios, aspect, 163
real-time strategy. See RTS
red, green, and blue. See RGB
reflection
Phong reflection models, 82-83, 292
relative coordinates, 218
Release builds, 306
rendering, 288
2D graphics, 20
graphics, 7
reports, issue tracking, 313
repositories, 309
representations
objects, 91
Resident Evil, 158
responses, collisions, 146-147
reticules, aiming, 211-212, 298
RGB (red, green, and blue), 20, 76
right hand rule, 52
Rock Band, 180
rotations
2D characters, 54
Euler, 292
matrices, 70
row-major vectors, 61
RTS (real-time strategy), 198
Rubine, Dean, 106
rules
parallelogram, 44
right hand, 52
Runge-Kutta method, 153
sample games
sample problems
2D characters, 54
scalar multiplication
matrices, 58
vectors, 47
Scaleform, 221
scale matrices, 69
scene nodes, 262
screens. See also interfaces
scripting languages, 239-241, 299
scrolling
2D graphics, 30
four-way, 34
infinite, 32
single-direction, 289
ScrollingLayer class, 264
SDKs (software development kits), 3
SDL (Simple DirectMedia Layer), 95
searching greedy best-first algorithms, 185-189
search spaces, representing, 181-183
Secure HTTP. See HTTPS
segments, lines, 129-130, 136-139
semi-implicit Euler integration, 151-152
sending
sequences, 94
numbers, 250
regular expressions, 231
serialization, 236
servers, 300
dedicated, 253
repositories, 309
server/client models, 250-253, 300
sets
closed, 186
open, 186
SetState function, 196
setsStitles, 289
setter functions, 271
settings, _Defense, 273
shaders, 66
colors, 76
Gouraud, 292
lighting, 79
Phong reflection models, 82-83
Ship Attack, 260
cocos2d, 262
Objective-C language, 261
Ship class, 265
side scrollers, 260
cocos2d, 262
Objective-C language, 261
Simple DirectMedia Layer. See SDL
Sims, The, 74
single-direction scrolling, 289
single models, 66
Singleton class, 274
Skyrim, 159
smartphones, 105
accelerometers/gyroscopes, 106-108
SNES era (1985-1995), 3
sockets, UDP, 250
software development kits. See SDKs
software rasterization, 66
Sommefeldt, Rhys, 47
sound
3D, 115
falloff, 118
basic, 112
source data, 112
cues, 294
_Defense, 282
obstruction, 123
source control, 309
diff/merging tools, 312
SVN, 309
source data
switches between, 114
space
dot products, 48
rotating 2D characters, 54
scalar multiplication, 47
specular component, 83
spheres
bounding, 131
intersections, 295
splines
Catmull-ROM, 296
spotlights, 81
spring follow cameras, 165-168
stacks
call stack windows, 307
Starcraft II, 256
Star Wars: The Old Republic, 221
state
finite state machines, 193-194
implementing state machines, 195-196
design patterns, 297
games
cheats, 256
_Defense, 275
machines
statements, if, 31
static objects, 13
storing functions, 293
subtraction
matrices, 58
subversion. See SVN
Super Mario Bros. 2, 34
support
surfaces, planes, 128
SVN (subversion), 309
swaps, buffers, 22
swept spheres, 295
switches between source data, 114
symbols, tokenization, 230
abstract trees, 299
Objective-C, 261
tablets, 105
accelerometers/gyroscopes, 106-108
tags, 310
tails (vectors), 43
TCP (Transmission Control Protocol), 246-249, 300
Team Fortress 2, 255
tearing, screen, 289
text
localization, 219
tokenization, 230
UI, hard-coding, 298
text-based files, 235
textures, 28
coordinates, 77
mapping, 77
time, 9
delta, 288
game time/real time, 10
logic as function of delta, 10-12
real, 288
variable time steps, 150
timeouts, 246
Timer class, 278
titles, sets, 289
tokenization, 230
tokens, 230
Tony Hawk’s Project 8, 205
tools
diff, 312
merging, 312
topologies, 250
tower defense games, 270
MonoGame, 273
XNA, 272
tracking issues, 313
tradeoffs
transforms
4D vectors by matrices, 69
multiple, 71
translation matrices, 70
Transmission Control Protocol. See TCP
transposes, matrices, 60
trees
abstract syntax, 299
octrees, 148
quadtrees, 148
trends in game programming, 4
triangles, 291
planes, 128
polygons, 66
Tribes, 250
troubleshooting
debuggers, 304
adding breakpoint conditions, 307
call stack windows, 307
data breakpoints, 308
issue tracking, 313
trunks, 310
types
of AI, 180
of cameras, 158
cutscene, 161
fixed, 158
non-player controlled, 158
of game objects, 13
of objects, 289
of scripting languages, 225-226
UDP (User Datagram Protocol), 249-250, 300
middleware, 221
multiple resolution support, 218-219
text, hard-coding, 298
Uncharted, 160
uniform scale, 70
unit quaternions, 90
unit vectors, 46
Unity, 4
unprojection, 296
Unreal, 4
Unreal Engines, 101
UpdateAnim function, 27
Update function, 196
UpdateInput function, 101
updating
servers, 301
worlds, 5
User Datagram Protocol. See UDP
user interfaces. See UIs
UV coordinates, 78
UX (user experience), 221, 299
variable time steps, 150
VBLANK (vertical blank interval), 20-21, 289
2D characters, rotating, 54
4D, transforming by matrices, 69
dot products, 48
scalar multiplication, 47
velocity, 252
collision responses, 146
Verlet integration, 152-153, 295
versions, IP, 245
vertical blank interval. See VBLANK
vertices, 66
normal, 78
video games, history of programming, 2
NES/SNES era (1985-1995), 3
Playstation/Playstation 2 era (1995-2005), 3
PS3/Wii/Xbox 360 era (2005-2013), 4
viewing call stack windows, 307
viewports, 163
field of, 295
virtual controllers, 105
virtual reality headsets, 94
visibility, 85
world transforms, 91
visual scripting systems, 229, 299
Visual Studio
breakpoints
conditions, 307
data, 308
call stack windows, 307
w-components, 68
whitepapers, 250
width, aspect ratios, 163
Wii era (2005-2013), 4
WiiMote, 94
winding order, 78
windows, call stack, 307
World of Warcraft, 227
TCP, 248
worlds
updating, 5
Xbox 360 era (2005-2013), 4
Xcode, 260
XCOM, 181
XML (Extensible Markup Language), 237
XNA game libraries, 272
z-fighting, 88
Zinman-Jeanes, Jacob, 260
zones, dead, 97