-
Notifications
You must be signed in to change notification settings - Fork 45
/
index.html
183 lines (174 loc) · 6.11 KB
/
index.html
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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
<!DOCTYPE html>
<html>
<head>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-155298280-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-155298280-1');
</script>
<meta charset="utf-8" />
<title>Spider-Man VR Experience</title>
<script src="https://connect.soundcloud.com/sdk/sdk-3.1.2.js"></script>
<script src="https://aframe.io/releases/1.0.3/aframe.min.js"></script>
<script src="hand.js"></script>
<script src="tile.js"></script>
<script src="map.js"></script>
<script src="player.js"></script>
<script src="web.js"></script>
<script src="gradient.js"></script>
<script src="radio.js"></script>
</head>
<body style="position: relative;">
<a-scene
renderer="highRefreshRate: false; colorManagement: true;"
fog="type: linear; color: #eafaff; far: 500;"
background="color: #eafaff;"
>
<a-sky
id="sky"
theta-length="110"
radius="900"
material="topColor: #87ceeb; bottomColor: #eafaff; shader: gradientshader; fog: false;"
></a-sky>
<a-assets>
<img
id="style1-building1-texture"
src="assets/s1b1.jpg"
preload="auto"
/>
<img
id="style1-building2-texture"
src="assets/s1b2.jpg"
preload="auto"
/>
<img
id="style1-building3-texture"
src="assets/s1b3.jpg"
preload="auto"
/>
<img
id="style1-building4-texture"
src="assets/s1b4.jpg"
preload="auto"
/>
<img
id="style1-building5-texture"
src="assets/s1b5.jpg"
preload="auto"
/>
<img
id="style1-building6-texture"
src="assets/s1b6.jpg"
preload="auto"
/>
<img
id="style1-building7-texture"
src="assets/s1b7.jpg"
preload="auto"
/>
<img
id="style1-building8-texture"
src="assets/s1b8.jpg"
preload="auto"
/>
<img
id="style1-building9-texture"
src="assets/s1b9.jpg"
preload="auto"
/>
<img
id="style1-building10-texture"
src="assets/s1b10.jpg"
preload="auto"
/>
<img
id="style1-building11-texture"
src="assets/s1b11.jpg"
preload="auto"
/>
<img
id="style1-ground1-texture"
src="assets/s1g1.jpg"
preload="auto"
/>
<img
id="style1-road1-texture"
src="assets/s1r1.jpg"
preload="auto"
/>
<a-mixin
id="tile"
tile="
buildingTextures: #style1-building1-texture, #style1-building2-texture, #style1-building3-texture, #style1-building4-texture, #style1-building5-texture, #style1-building6-texture, #style1-building7-texture, #style1-building8-texture, #style1-building9-texture, #style1-building10-texture, #style1-building11-texture;
buildingColors: #9eafcb, #a6bee4, #cca49a, #818c9f, #9aaec6, #484a57, #c7afa3, #7b9fbf, #123459, #a3b3cd, #c5a495;
groundTextures: #style1-ground1-texture;
groundColors: #9aaacc;
roadTextures: #style1-road1-texture;
roadColors: #373943;"
></a-mixin>
<a-asset-item
id="crystal"
src="assets/crystal-fast.glb"
preload="auto"
></a-asset-item>
<audio
id="sound-shoot-web"
src="assets/shoot-web.mp3"
preload="auto"
></audio>
<audio
id="sound-no-web"
src="assets/no-web.mp3"
preload="auto"
></audio>
<audio
id="sound-hit-wall"
src="assets/hit-wall.mp3"
preload="auto"
></audio>
<audio
id="sound-hit-ground"
src="assets/hit-ground.mp3"
preload="auto"
></audio>
<audio
id="sound-hit-crystal"
src="assets/hit-crystal.mp3"
></audio>
<audio
id="sound-crystal"
src="assets/crystal.mp3"
></audio>
</a-assets>
<a-entity light="type:ambient; color:#e8e8e8"></a-entity>
<a-entity light="type: directional; color: #FFF; intensity: 0.6;" position="-0.5 1 1"></a-entity>
<a-entity id="map" map="" pool="mixin: tile; size: 50; container: #map; dynamic: true;"></a-entity>
<a-entity player="mass: 70" position="0 0 0"></a-entity>
<a-entity id="web-right" web="" position="0 0 0"></a-entity>
<a-entity id="web-left" web="" position="0 0 0"></a-entity>
<a-entity
radio="tracks: 516082875, 495963048, 564400320, 520701015, 503039229, 283366526, 27657719, 4476253; weights: 50, 50, 50, 50, 50, 50, 30, 20;"
></a-entity>
</a-scene>
<div
style="z-index: 1; position: absolute;
top: 10%; left: 5%; bottom: 10%; right: 5%;
padding: 1% 20% 1% 5%;
font-family: sans-serif,monospace; font-size: 20px; font-weight: 300;
background-repeat: no-repeat; background-color: #a40000; background-position-x: right; background-size: contain;
background-image: url(assets/background.png);"
>
<p><span style="color: white;">Movement:</span> Hold the triggers to shoot webs and zip through the city.</p>
<p><span style="color: white;">Challenge:</span> How many crystals can you collect without hitting walls?</p>
<p>
<span style="color: white;">Advanced:</span> Hold thumbstick up/down before shooting to control length. Hold
grip button for sharper turns.
</p>
<p style="color: white;">Click the VR button on the bottom right to start! VR headset required.</p>
<p style="font-size: 12px;">Unofficial, fan-made, open source - <a href="https://github.com/talkol/spiderman" style="font-size: 12px; color: black;">https://github.com/talkol/spiderman</a></p>
</div>
</body>
</html>