Code: The Purple Fruit Monster Game

This is the final version of the game code from Chapter 15, Project: The Purple Fruit Monster Game.

<script src="​"></script>
<script src="​http:​//"></script>
<script src="">​</script>
<script src="​"></script>
// This is where stuff in our game will happen:
Physijs.scripts.ammo = '';
Physijs.scripts.worker = '';
var scene = new Physijs.Scene({ fixedTimeStep: 2 / 60 });
scene.setGravity(new THREE.Vector3( 0, -100, 0 ));
// This is what sees the stuff:
var aspect_ratio ...

Get 3D Game Programming for Kids now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.