Reader small image

You're reading from  Game Development with Three.js

Product typeBook
Published inOct 2013
Reading LevelIntermediate
PublisherPackt
ISBN-139781782168539
Edition1st Edition
Languages
Right arrow
Author (1)
Isaac Sukin
Isaac Sukin
author image
Isaac Sukin

Isaac Sukin has been building games since he was eight years old, when he discovered that Nerf Arena Blast came with a copy of Epic Games' Unreal Editor. At 16, he became co-leader of the Community Bonus Pack team, an international group of game developers for the Unreal Engine that won 49 awards over the next few years. He started learning to code around the same time by developing an open source Facebook-style statuses system that thousands of websites have adopted. Since then, he has been increasingly drawn to interactive JavaScript on the web. He created an open source 2D game engine in early 2012 and then dove into Three.js. As of 2013, he is a senior, studying entrepreneurship and information management at the Wharton school at the University of Pennsylvania. He has worked for Twitter, First Round Capital, and Acquia among others, and was previously a freelance consultant and developer. He is also a founder of Dorm Room Fund, a student-run venture capital fund that invests in student-run startups. You can find him on GitHub and Twitter under the alias IceCreamYou or visit his website at www.isaacsukin.com. He has previously published short stories and poetry, but this is his first book.
Read more about Isaac Sukin

Right arrow

First-person shooter project


Let's write a real game! This project will be bigger than any others we've done, so let's start by specifying exactly what to accomplish. We're going to build an arena-based first-person shooter game with the following features:

  • A world based on a voxel map

  • A player that can look, run, and jump around in the world

  • Pointer lock and full-screen, so that the player is fully immersed as in a desktop or console game

  • The player should be able to shoot at enemies that wander around, and the enemies should shoot back

  • The player's and enemies' health should deteriorate when shot, and players should respawn when they run out of health

  • The player's screen should flash red when shot

  • There should be a HUD (heads-up display) with crosshairs and a health indicator

  • We do not care much about lighting or texturing, except that the player must be able to see and perceive distances in depth

Note

The complete code is too long to include here, but you can download it online from your account...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Game Development with Three.js
Published in: Oct 2013Publisher: PacktISBN-13: 9781782168539

Author (1)

author image
Isaac Sukin

Isaac Sukin has been building games since he was eight years old, when he discovered that Nerf Arena Blast came with a copy of Epic Games' Unreal Editor. At 16, he became co-leader of the Community Bonus Pack team, an international group of game developers for the Unreal Engine that won 49 awards over the next few years. He started learning to code around the same time by developing an open source Facebook-style statuses system that thousands of websites have adopted. Since then, he has been increasingly drawn to interactive JavaScript on the web. He created an open source 2D game engine in early 2012 and then dove into Three.js. As of 2013, he is a senior, studying entrepreneurship and information management at the Wharton school at the University of Pennsylvania. He has worked for Twitter, First Round Capital, and Acquia among others, and was previously a freelance consultant and developer. He is also a founder of Dorm Room Fund, a student-run venture capital fund that invests in student-run startups. You can find him on GitHub and Twitter under the alias IceCreamYou or visit his website at www.isaacsukin.com. He has previously published short stories and poetry, but this is his first book.
Read more about Isaac Sukin