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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
var environment = new function(){}
environment.init = function () {
cam.rotationY = -3.77
//controls.init(cam, scene)
cam.z = -200
cam.x = 400
var borderColor = '#000'
// set up objects
center = {}
center.z = 900
doorWidth = 300
doorHeight = 450
doorOffset = 0
wallColor = 'rgba(255,255,255,0.85)'
box = new MX.BoxDimensions({
width: 2000,
height: 900,
depth: 2000,
color: wallColor,
borderColor: borderColor,
sides: "top bottom left right back",
tag: "bigroom"
})
box.z = 500 - center.z
scene.add(box)
box = new MX.BoxDimensions({
width: 1000,
height: 900,
depth: 1000,
color: wallColor,
borderColor: borderColor,
sides: "top bottom left right front",
tag: "smallroom"
})
box.z = -500 - 200 - 500 - center.z
scene.add(box)
hall = new MX.BoxDimensions({
width: doorWidth,
height: doorHeight,
depth: 200,
color: wallColor,
borderColor: borderColor,
sides: "top bottom left right",
tag: "hall"
})
hall.z = -600- center.z
scene.add(hall)
door = new MX.Door({
width: 2000,
height: 900,
doorWidth: doorWidth,
doorHeight: doorHeight,
doorOffset: doorOffset,
color: wallColor,
borderColor: borderColor
})
door.z = -500 - center.z
scene.add(door)
door = new MX.Door({
width: 1000,
height: 900,
doorWidth: doorWidth,
doorHeight: doorHeight,
doorOffset: doorOffset,
color: wallColor,
borderColor: borderColor
})
door.z = -700 - center.z
scene.add(door)
var image = environment.image = new MX.Image({
src: "https://s3.amazonaws.com/luckyplop/f5b2c20e602cdfc86383910f294dcf23d91fa956.png",
x: -990,
y: 450,
z: 0 - center.z,
})
image.rotationY = MX.toRad(90)
scene.add(image)
var video = environment.video = new MX.Video({
src: "//www.dotdash3.com/video/svvnDp9_Q1s.mp4",
x: 0,
y: 300,
z: -500 - 200 - 500 - 450 - center.z,
})
video.rotationY = MX.toRad(180)
scene.add(video)
}
|