You are previewing 3D Game Programming for Kids.
O'Reilly logo
3D Game Programming for Kids

Book Description

You know what's even better than playing games? Creating your own. Even if you're an absolute beginner, this book will teach you how to make your own online games with interactive examples. You'll learn programming using nothing more than a browser, and see cool, 3D results as you type. You'll learn real-world programming skills in a real programming language: JavaScript, the language of the web. You'll be amazed at what you can do as you build interactive worlds and fun games.

Table of Contents

  1. 3D Game Programming for Kids
  2. For the Best Reading Experience...
  3. Table of Contents
  4. Early praise for 3D Game Programming for Kids
  5. Acknowledgments
  6. Introduction
    1. How I Learned to Program
    2. What You Need for This Book
    3. What Is JavaScript?
    4. How to Read This Book
    5. Let’s Get Started!
  7. Chapter 1: Project: Creating Simple Shapes
    1. Programming with the ICE Code Editor
    2. Making Shapes with JavaScript
    3. Animating the Shapes
    4. The Code So Far
    5. What’s Next
  8. Chapter 2: Playing with the Console and Finding What’s Broken
    1. Getting Started
    2. Opening and Closing the JavaScript Console
    3. Debugging in ICE: The Red X
    4. Debugging in ICE: The Yellow Triangle
    5. Debugging in the Console
    6. Recovering When ICE Is Broken
    7. What’s Next
  9. Chapter 3: Project: Making an Avatar
    1. Getting Started
    2. Making a Whole from Parts
    3. Breaking It Down
    4. Adding Feet for Walking
    5. Challenge: Make the Avatar Your Own
    6. Doing Cartwheels
    7. The Code So Far
    8. What’s Next
  10. Chapter 4: Project: Moving Avatars
    1. Getting Started
    2. Building Interactive Systems with Keyboard Events
    3. Converting Keyboard Events into Avatar Movement
    4. Challenge: Start/Stop Animation
    5. Building a Forest with Functions
    6. Moving the Camera with the Avatar
    7. The Code So Far
    8. What’s Next
  11. Chapter 5: Functions: Use and Use Again
    1. Getting Started
    2. Understanding Simple Functions
    3. When Things Go Wrong
    4. Weird Tricks with Functions
    5. The Code So Far
    6. What’s Next
  12. Chapter 6: Project: Moving Hands and Feet
    1. Getting Started
    2. Moving a Hand
    3. Swinging Hands and Feet Together
    4. Walking When Moving
    5. The Code So Far
    6. What’s Next
  13. Chapter 7: A Closer Look at JavaScript Fundamentals
    1. Getting Started
    2. Describing a Thing in JavaScript
    3. Changing Things
    4. Repeating and Skipping Code with while and if
    5. Listing Things
    6. What Makes JavaScript Different
    7. What’s Next
  14. Chapter 8: Project: Turning Our Avatar
    1. Getting Started
    2. Facing the Proper Direction
    3. Breaking It Down
    4. Animating the Spin
    5. The Code So Far
    6. What’s Next
  15. Chapter 9: What’s All That Other Code?
    1. Getting Started
    2. A Quick Introduction to HTML
    3. Setting the Scene
    4. Using Cameras to Capture the Scene
    5. Using a Renderer to Project What the Camera Sees
    6. Exploring Different Cameras and Renderers
    7. What’s Next
  16. Chapter 10: Project: Collisions
    1. Getting Started
    2. Rays and Intersections
    3. The Code So Far
    4. What’s Next
  17. Chapter 11: Project: Fruit Hunt
    1. Getting Started
    2. Starting a Scoreboard at Zero
    3. Giving Trees a Little Wiggle
    4. Jumping for Points
    5. Making Our Games Even Better
    6. The Code So Far
    7. What’s Next
  18. Chapter 12: Working with Lights and Materials
    1. Getting Started
    2. Changing Color
    3. Realism: Shininess
    4. Shadows
    5. Let’s Animate!
    6. The Code So Far
    7. What’s Next
  19. Chapter 13: Project: Build Your Own Solar System
    1. Getting Started
    2. The Sun, Earth, and Mars
    3. Earth-Cam!
    4. The Code So Far
    5. What’s Next
  20. Chapter 14: Project: Phases of the Moon
    1. Getting Started
    2. Change Mars into the Moon
    3. The Coolest Trick: Frame of Reference
    4. Challenge: Create an Earth Orbit Frame of Reference
    5. Pausing the Simulation
    6. Understanding the Phases
    7. The Code So Far
    8. What’s Next
  21. Chapter 15: Project: The Purple Fruit Monster Game
    1. Getting Started
    2. Let’s Make Physics!
    3. Outline the Game
    4. The Code So Far
    5. What’s Next
  22. Chapter 16: Project: Tilt-a-Board
    1. Getting Started
    2. Gravity and Other Setup
    3. Outline the Game
    4. The Code So Far
    5. What’s Next
  23. Chapter 17: Project: Learning about JavaScript Objects
    1. Getting Started
    2. Simple Objects
    3. Copying Objects
    4. Constructing New Objects
    5. The Code So Far
    6. What’s Next
  24. Chapter 18: Project: Cave Puzzle
    1. Getting Started
    2. Setting the Game’s Boundaries
    3. Building a Random, Unreachable Goal
    4. Building Draggable Ramps
    5. Winning the Game
    6. The Code So Far
    7. What’s Next
  25. Chapter 19: Project: Multilevel Game
    1. Getting Started
    2. Building Levels
    3. Adding Finishing Touches to the Game
    4. The Code So Far
    5. What’s Next
  26. Chapter 20: Project: River Rafting
    1. Getting Started
    2. Organizing Code
    3. Warping Shapes to Make Unique Things
    4. Build a Raft for Racing
    5. Setting the Finish Line
    6. The Code So Far
    7. What’s Next
  27. Chapter 21: Getting Code on the Web
    1. The Mighty, Mighty Browser
    2. Free Websites
    3. Putting Your Code on Another Site
    4. What’s Next
  28. Appendix 1: Project Code
    1. Code: Creating Simple Shapes
    2. Code: Playing with the Console and Finding What’s Broken
    3. Code: Making an Avatar
    4. Code: Moving Avatars
    5. Code: Functions: Use and Use Again
    6. Code: Moving Hands and Feet
    7. Code: A Closer Look at JavaScript Fundamentals
    8. Code: Turning Our Avatar
    9. Code: What’s All That Other Code?
    10. Code: Collisions
    11. Code: Fruit Hunt
    12. Code: Working with Lights and Materials
    13. Code: Build Your Own Solar System
    14. Code: Phases of the Moon
    15. Code: The Purple Fruit Monster Game
    16. Code: Tilt-a-Board
    17. Code: Learning about JavaScript Objects
    18. Code: Cave Puzzle
    19. Code: Multilevel Game
    20. Code: River Rafting
  29. Appendix 2: JavaScript Libraries Used in This Book
    1. Three.js
    2. Physijs
    3. Tween.js
    4. Scoreboard.js
    5. Sounds.js
    6. You May Be Interested In…