summaryrefslogtreecommitdiff
path: root/assets/javascripts/rectangles/_env.js
blob: 11e01baa833a6b762fe13b882962c8a6a6ab5442 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
var environment = new function(){}
environment.init = function(){
	window.scene && scene.camera.move({
		"x": 240,
		"y": -1000,
		"z": 240,
		"rotationX": -PI/2,
		"rotationY": 0 // PI
	})

	clipper.rooms.push( new room ({
		rect: new rect(100,100, 200,300),
		height: 400,
	}))
	clipper.rooms.push( new room ({
		rect: new rect(200,300, 300,500),
		height: 300,
	}))
	clipper.rooms.push( new room ({
		rect: new rect(300,100, 600,300),
		height: 400,
	}))
	clipper.rooms.push( new room ({
		rect: new rect(400,200, 700,400),
		height: 500,
	}))

	builder.init()
	clipper.init()
	window.scene && scene.update()
}
environment.update = function(t){
	clipper.animate()
}