Skip to content

Commit 738f5d0

Browse files
committed
Add in a plane to represent the ground, change bg color, improve asthetics
1 parent be0c729 commit 738f5d0

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

public/scripts.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,17 @@ scene.add(lights[0]);
4141
scene.add(lights[1]);
4242
scene.add(lights[2]);
4343

44+
var plane = new THREE.Mesh(
45+
new THREE.PlaneBufferGeometry( 1000, 1000 ),
46+
new THREE.MeshBasicMaterial( { color: 0x997744 } )
47+
);
48+
plane.rotation.x = - Math.PI / 2;
49+
plane.position.y = -1;
50+
//plane.receiveShadow = true;
51+
scene.add( plane );
52+
53+
scene.background = new THREE.Color( 0x99ffff );
54+
4455
var jumping = false;
4556
var jump_distance = 0.1;
4657
var acceleration = 0.0025;

0 commit comments

Comments
 (0)