chengzl18 commited on
Commit
751b8c9
·
verified ·
1 Parent(s): d50344d

Upload folder using huggingface_hub

Browse files
.gitattributes CHANGED
@@ -47,3 +47,7 @@ StreamingAssets/aa/WebGL/lowpolyinterior2_assets_all_4a73d1ff1ebc52c3da3dcf77de5
47
  Build/202405062013.data filter=lfs diff=lfs merge=lfs -text
48
  Build/202405062033.data filter=lfs diff=lfs merge=lfs -text
49
  Build/202405071939.data filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
47
  Build/202405062013.data filter=lfs diff=lfs merge=lfs -text
48
  Build/202405062033.data filter=lfs diff=lfs merge=lfs -text
49
  Build/202405071939.data filter=lfs diff=lfs merge=lfs -text
50
+ Build/202408130439.data filter=lfs diff=lfs merge=lfs -text
51
+ StreamingAssets/aa/WebGL/lowpolyinterior2_assets_all_92e55feb430f06d5d25422f36914075a.bundle filter=lfs diff=lfs merge=lfs -text
52
+ StreamingAssets/aa/WebGL/lowpolyinterior_assets_all_dac3ef8b16666c3b3ee95e6d9bffb1b8.bundle filter=lfs diff=lfs merge=lfs -text
53
+ StreamingAssets/aa/WebGL/worldmaterialsfree_assets_all_abfeef79148fe6d5779541a3bca55136.bundle filter=lfs diff=lfs merge=lfs -text
Build/202408130439.data ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3d02fa4ade6c662e59a74ec9eac8ac2e3e26d86081f6d91c05aca288d00d45e5
3
+ size 81125433
Build/202408130439.framework.js ADDED
The diff for this file is too large to render. See raw diff
 
Build/202408130439.loader.js ADDED
@@ -0,0 +1,1271 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ function createUnityInstance(canvas, config, onProgress) {
2
+ onProgress = onProgress || function () {};
3
+
4
+
5
+ function showBanner(msg, type) {
6
+ // Only ever show one error at most - other banner messages after that should get ignored
7
+ // to avoid noise.
8
+ if (!showBanner.aborted && config.showBanner) {
9
+ if (type == 'error') showBanner.aborted = true;
10
+ return config.showBanner(msg, type);
11
+ }
12
+
13
+ // Fallback to console logging if visible banners have been suppressed
14
+ // from the main page.
15
+ switch(type) {
16
+ case 'error': console.error(msg); break;
17
+ case 'warning': console.warn(msg); break;
18
+ default: console.log(msg); break;
19
+ }
20
+ }
21
+
22
+ function errorListener(e) {
23
+ var error = e.reason || e.error;
24
+ var message = error ? error.toString() : (e.message || e.reason || '');
25
+ var stack = (error && error.stack) ? error.stack.toString() : '';
26
+
27
+ // Do not repeat the error message if it's present in the stack trace.
28
+ if (stack.startsWith(message)) {
29
+ stack = stack.substring(message.length);
30
+ }
31
+
32
+ message += '\n' + stack.trim();
33
+
34
+ if (!message || !Module.stackTraceRegExp || !Module.stackTraceRegExp.test(message))
35
+ return;
36
+
37
+ var filename = e.filename || (error && (error.fileName || error.sourceURL)) || '';
38
+ var lineno = e.lineno || (error && (error.lineNumber || error.line)) || 0;
39
+
40
+ errorHandler(message, filename, lineno);
41
+ }
42
+
43
+ function fallbackToDefaultConfigWithWarning(config, key, defaultValue) {
44
+ var value = config[key];
45
+
46
+ if (typeof value === "undefined" || !value) {
47
+ console.warn("Config option \"" + key + "\" is missing or empty. Falling back to default value: \"" + defaultValue + "\". Consider updating your WebGL template to include the missing config option.");
48
+ config[key] = defaultValue;
49
+ }
50
+ }
51
+
52
+ var Module = {
53
+ canvas: canvas,
54
+ webglContextAttributes: {
55
+ preserveDrawingBuffer: false,
56
+ powerPreference: 2,
57
+ },
58
+ cacheControl: function (url) {
59
+ return (url == Module.dataUrl || url.match(/\.bundle/)) ? "must-revalidate" : "no-store";
60
+ },
61
+ streamingAssetsUrl: "StreamingAssets",
62
+ downloadProgress: {},
63
+ deinitializers: [],
64
+ intervals: {},
65
+ setInterval: function (func, ms) {
66
+ var id = window.setInterval(func, ms);
67
+ this.intervals[id] = true;
68
+ return id;
69
+ },
70
+ clearInterval: function(id) {
71
+ delete this.intervals[id];
72
+ window.clearInterval(id);
73
+ },
74
+ preRun: [],
75
+ postRun: [],
76
+ print: function (message) {
77
+ console.log(message);
78
+ },
79
+ printErr: function (message) {
80
+ console.error(message);
81
+
82
+ if (typeof message === 'string' && message.indexOf('wasm streaming compile failed') != -1) {
83
+ if (message.toLowerCase().indexOf('mime') != -1) {
84
+ showBanner('HTTP Response Header "Content-Type" configured incorrectly on the server for file ' + Module.codeUrl + ' , should be "application/wasm". Startup time performance will suffer.', 'warning');
85
+ } else {
86
+ showBanner('WebAssembly streaming compilation failed! This can happen for example if "Content-Encoding" HTTP header is incorrectly enabled on the server for file ' + Module.codeUrl + ', but the file is not pre-compressed on disk (or vice versa). Check the Network tab in browser Devtools to debug server header configuration.', 'warning');
87
+ }
88
+ }
89
+ },
90
+ locateFile: function (url) {
91
+ if (url == "build.wasm") return this.codeUrl;
92
+ return url;
93
+ },
94
+ disabledCanvasEvents: [
95
+ "contextmenu",
96
+ "dragstart",
97
+ ],
98
+ };
99
+
100
+ // Add fallback values for companyName, productName and productVersion to ensure that the UnityCache is working.
101
+ fallbackToDefaultConfigWithWarning(config, "companyName", "Unity");
102
+ fallbackToDefaultConfigWithWarning(config, "productName", "WebGL Player");
103
+ fallbackToDefaultConfigWithWarning(config, "productVersion", "1.0");
104
+
105
+ for (var parameter in config)
106
+ Module[parameter] = config[parameter];
107
+
108
+ Module.streamingAssetsUrl = new URL(Module.streamingAssetsUrl, document.URL).href;
109
+
110
+ // Operate on a clone of Module.disabledCanvasEvents field so that at Quit time
111
+ // we will ensure we'll remove the events that we created (in case user has
112
+ // modified/cleared Module.disabledCanvasEvents in between)
113
+ var disabledCanvasEvents = Module.disabledCanvasEvents.slice();
114
+
115
+ function preventDefault(e) {
116
+ e.preventDefault();
117
+ }
118
+
119
+ disabledCanvasEvents.forEach(function (disabledCanvasEvent) {
120
+ canvas.addEventListener(disabledCanvasEvent, preventDefault);
121
+ });
122
+
123
+ window.addEventListener("error", errorListener);
124
+ window.addEventListener("unhandledrejection", errorListener);
125
+
126
+ // Safari does not automatically stretch the fullscreen element to fill the screen.
127
+ // The CSS width/height of the canvas causes it to remain the same size in the full screen
128
+ // window on Safari, resulting in it being a small canvas with black borders filling the
129
+ // rest of the screen.
130
+ var _savedElementWidth = "";
131
+ var _savedElementHeight = "";
132
+ function webkitFullscreenChangeEventHandler(e) {
133
+ // Safari uses webkitCurrentFullScreenElement and not fullscreenElement.
134
+ var fullscreenElement = document.webkitCurrentFullScreenElement;
135
+ if (fullscreenElement === canvas) {
136
+ if (canvas.style.width) {
137
+ _savedElementWidth = canvas.style.width;
138
+ _savedElementHeight = canvas.style.height;
139
+ canvas.style.width = "100%";
140
+ canvas.style.height = "100%";
141
+ }
142
+ } else {
143
+ if (_savedElementWidth) {
144
+ canvas.style.width = _savedElementWidth;
145
+ canvas.style.height = _savedElementHeight;
146
+ _savedElementWidth = "";
147
+ _savedElementHeight = "";
148
+ }
149
+ }
150
+ }
151
+ // Safari uses webkitfullscreenchange event and not fullscreenchange
152
+ document.addEventListener("webkitfullscreenchange", webkitFullscreenChangeEventHandler);
153
+
154
+ // Clear the event handlers we added above when the app quits, so that the event handler
155
+ // functions will not hold references to this JS function scope after
156
+ // exit, to allow JS garbage collection to take place.
157
+ Module.deinitializers.push(function() {
158
+ Module['disableAccessToMediaDevices']();
159
+ disabledCanvasEvents.forEach(function (disabledCanvasEvent) {
160
+ canvas.removeEventListener(disabledCanvasEvent, preventDefault);
161
+ });
162
+ window.removeEventListener("error", errorListener);
163
+ window.removeEventListener("unhandledrejection", errorListener);
164
+
165
+ document.removeEventListener("webkitfullscreenchange", webkitFullscreenChangeEventHandler);
166
+
167
+ for (var id in Module.intervals)
168
+ {
169
+ window.clearInterval(id);
170
+ }
171
+ Module.intervals = {};
172
+ });
173
+
174
+ Module.QuitCleanup = function () {
175
+ for (var i = 0; i < Module.deinitializers.length; i++) {
176
+ Module.deinitializers[i]();
177
+ }
178
+ Module.deinitializers = [];
179
+ // After all deinitializer callbacks are called, notify user code that the Unity game instance has now shut down.
180
+ if (typeof Module.onQuit == "function")
181
+ Module.onQuit();
182
+
183
+ };
184
+
185
+ var unityInstance = {
186
+ Module: Module,
187
+ SetFullscreen: function () {
188
+ if (Module.SetFullscreen)
189
+ return Module.SetFullscreen.apply(Module, arguments);
190
+ Module.print("Failed to set Fullscreen mode: Player not loaded yet.");
191
+ },
192
+ SendMessage: function () {
193
+ if (Module.SendMessage)
194
+ return Module.SendMessage.apply(Module, arguments);
195
+ Module.print("Failed to execute SendMessage: Player not loaded yet.");
196
+ },
197
+ Quit: function () {
198
+ return new Promise(function (resolve, reject) {
199
+ Module.shouldQuit = true;
200
+ Module.onQuit = resolve;
201
+ });
202
+ },
203
+ GetMemoryInfo: function () {
204
+ var memInfoPtr = Module._getMemInfo();
205
+ return {
206
+ totalWASMHeapSize: Module.HEAPU32[memInfoPtr >> 2],
207
+ usedWASMHeapSize: Module.HEAPU32[(memInfoPtr >> 2) + 1],
208
+ totalJSHeapSize: Module.HEAPF64[(memInfoPtr >> 3) + 1],
209
+ usedJSHeapSize: Module.HEAPF64[(memInfoPtr >> 3) + 2]
210
+ };
211
+ },
212
+ };
213
+
214
+
215
+ Module.SystemInfo = (function () {
216
+
217
+ var browser, browserVersion, os, osVersion, canvas, gpu;
218
+
219
+ var ua = navigator.userAgent + ' ';
220
+ var browsers = [
221
+ ['Firefox', 'Firefox'],
222
+ ['OPR', 'Opera'],
223
+ ['Edg', 'Edge'],
224
+ ['SamsungBrowser', 'Samsung Browser'],
225
+ ['Trident', 'Internet Explorer'],
226
+ ['MSIE', 'Internet Explorer'],
227
+ ['Chrome', 'Chrome'],
228
+ ['CriOS', 'Chrome on iOS Safari'],
229
+ ['FxiOS', 'Firefox on iOS Safari'],
230
+ ['Safari', 'Safari'],
231
+ ];
232
+
233
+ function extractRe(re, str, idx) {
234
+ re = RegExp(re, 'i').exec(str);
235
+ return re && re[idx];
236
+ }
237
+ for(var b = 0; b < browsers.length; ++b) {
238
+ browserVersion = extractRe(browsers[b][0] + '[\/ ](.*?)[ \\)]', ua, 1);
239
+ if (browserVersion) {
240
+ browser = browsers[b][1];
241
+ break;
242
+ }
243
+ }
244
+ if (browser == 'Safari') browserVersion = extractRe('Version\/(.*?) ', ua, 1);
245
+ if (browser == 'Internet Explorer') browserVersion = extractRe('rv:(.*?)\\)? ', ua, 1) || browserVersion;
246
+
247
+ // These OS strings need to match the ones in Runtime/Misc/SystemInfo.cpp::GetOperatingSystemFamily()
248
+ var oses = [
249
+ ['Windows (.*?)[;\)]', 'Windows'],
250
+ ['Android ([0-9_\.]+)', 'Android'],
251
+ ['iPhone OS ([0-9_\.]+)', 'iPhoneOS'],
252
+ ['iPad.*? OS ([0-9_\.]+)', 'iPadOS'],
253
+ ['FreeBSD( )', 'FreeBSD'],
254
+ ['OpenBSD( )', 'OpenBSD'],
255
+ ['Linux|X11()', 'Linux'],
256
+ ['Mac OS X ([0-9_\\.]+)', 'MacOS'],
257
+ ['bot|google|baidu|bing|msn|teoma|slurp|yandex', 'Search Bot']
258
+ ];
259
+ for(var o = 0; o < oses.length; ++o) {
260
+ osVersion = extractRe(oses[o][0], ua, 1);
261
+ if (osVersion) {
262
+ os = oses[o][1];
263
+ osVersion = osVersion.replace(/_/g, '.');
264
+ break;
265
+ }
266
+ }
267
+ var versionMappings = {
268
+ 'NT 5.0': '2000',
269
+ 'NT 5.1': 'XP',
270
+ 'NT 5.2': 'Server 2003',
271
+ 'NT 6.0': 'Vista',
272
+ 'NT 6.1': '7',
273
+ 'NT 6.2': '8',
274
+ 'NT 6.3': '8.1',
275
+ 'NT 10.0': '10'
276
+ };
277
+ osVersion = versionMappings[osVersion] || osVersion;
278
+
279
+ // TODO: Add mobile device identifier, e.g. SM-G960U
280
+
281
+ canvas = document.createElement("canvas");
282
+ if (canvas) {
283
+ var gl = canvas.getContext("webgl2");
284
+ var glVersion = gl ? 2 : 0;
285
+ if (!gl) {
286
+ if (gl = canvas && canvas.getContext("webgl")) glVersion = 1;
287
+ }
288
+
289
+ if (gl) {
290
+ gpu = (gl.getExtension("WEBGL_debug_renderer_info") && gl.getParameter(0x9246 /*debugRendererInfo.UNMASKED_RENDERER_WEBGL*/)) || gl.getParameter(0x1F01 /*gl.RENDERER*/);
291
+ }
292
+ }
293
+
294
+ var hasThreads = typeof SharedArrayBuffer !== 'undefined';
295
+ var hasWasm = typeof WebAssembly === "object" && typeof WebAssembly.compile === "function";
296
+ return {
297
+ width: screen.width,
298
+ height: screen.height,
299
+ userAgent: ua.trim(),
300
+ browser: browser || 'Unknown browser',
301
+ browserVersion: browserVersion || 'Unknown version',
302
+ mobile: /Mobile|Android|iP(ad|hone)/.test(navigator.appVersion),
303
+ os: os || 'Unknown OS',
304
+ osVersion: osVersion || 'Unknown OS Version',
305
+ gpu: gpu || 'Unknown GPU',
306
+ language: navigator.userLanguage || navigator.language,
307
+ hasWebGL: glVersion,
308
+ hasCursorLock: !!document.body.requestPointerLock,
309
+ hasFullscreen: !!document.body.requestFullscreen || !!document.body.webkitRequestFullscreen, // Safari still uses the webkit prefixed version
310
+ hasThreads: hasThreads,
311
+ hasWasm: hasWasm,
312
+ // This should be updated when we re-enable wasm threads. Previously it checked for WASM thread
313
+ // support with: var wasmMemory = hasWasm && hasThreads && new WebAssembly.Memory({"initial": 1, "maximum": 1, "shared": true});
314
+ // which caused Chrome to have a warning that SharedArrayBuffer requires cross origin isolation.
315
+ hasWasmThreads: false,
316
+ };
317
+ })();
318
+
319
+ function errorHandler(message, filename, lineno) {
320
+ // Unity needs to rely on Emscripten deferred fullscreen requests, so these will make their way to error handler
321
+ if (message.indexOf('fullscreen error') != -1)
322
+ return;
323
+
324
+ if (Module.startupErrorHandler) {
325
+ Module.startupErrorHandler(message, filename, lineno);
326
+ return;
327
+ }
328
+ if (Module.errorHandler && Module.errorHandler(message, filename, lineno))
329
+ return;
330
+ console.log("Invoking error handler due to\n" + message);
331
+
332
+ // Support Firefox window.dump functionality.
333
+ if (typeof dump == "function")
334
+ dump("Invoking error handler due to\n" + message);
335
+
336
+ if (errorHandler.didShowErrorMessage)
337
+ return;
338
+ var message = "An error occurred running the Unity content on this page. See your browser JavaScript console for more info. The error was:\n" + message;
339
+ if (message.indexOf("DISABLE_EXCEPTION_CATCHING") != -1) {
340
+ message = "An exception has occurred, but exception handling has been disabled in this build. If you are the developer of this content, enable exceptions in your project WebGL player settings to be able to catch the exception or see the stack trace.";
341
+ } else if (message.indexOf("Cannot enlarge memory arrays") != -1) {
342
+ message = "Out of memory. If you are the developer of this content, try allocating more memory to your WebGL build in the WebGL player settings.";
343
+ } else if (message.indexOf("Invalid array buffer length") != -1 || message.indexOf("Invalid typed array length") != -1 || message.indexOf("out of memory") != -1 || message.indexOf("could not allocate memory") != -1) {
344
+ message = "The browser could not allocate enough memory for the WebGL content. If you are the developer of this content, try allocating less memory to your WebGL build in the WebGL player settings.";
345
+ }
346
+ alert(message);
347
+ errorHandler.didShowErrorMessage = true;
348
+ }
349
+
350
+
351
+ Module.abortHandler = function (message) {
352
+ errorHandler(message, "", 0);
353
+ return true;
354
+ };
355
+
356
+ Error.stackTraceLimit = Math.max(Error.stackTraceLimit || 0, 50);
357
+
358
+ function progressUpdate(id, e) {
359
+ if (id == "symbolsUrl")
360
+ return;
361
+ var progress = Module.downloadProgress[id];
362
+ if (!progress)
363
+ progress = Module.downloadProgress[id] = {
364
+ started: false,
365
+ finished: false,
366
+ lengthComputable: false,
367
+ total: 0,
368
+ loaded: 0,
369
+ };
370
+ if (typeof e == "object" && (e.type == "progress" || e.type == "load")) {
371
+ if (!progress.started) {
372
+ progress.started = true;
373
+ progress.lengthComputable = e.lengthComputable;
374
+ }
375
+ progress.total = e.total;
376
+ progress.loaded = e.loaded;
377
+ if (e.type == "load")
378
+ progress.finished = true;
379
+ }
380
+ var loaded = 0, total = 0, started = 0, computable = 0, unfinishedNonComputable = 0;
381
+ for (var id in Module.downloadProgress) {
382
+ var progress = Module.downloadProgress[id];
383
+ if (!progress.started)
384
+ return 0;
385
+ started++;
386
+ if (progress.lengthComputable) {
387
+ loaded += progress.loaded;
388
+ total += progress.total;
389
+ computable++;
390
+ } else if (!progress.finished) {
391
+ unfinishedNonComputable++;
392
+ }
393
+ }
394
+ var totalProgress = started ? (started - unfinishedNonComputable - (total ? computable * (total - loaded) / total : 0)) / started : 0;
395
+ onProgress(0.9 * totalProgress);
396
+ }
397
+
398
+ Module.readBodyWithProgress = function() {
399
+ /**
400
+ * Estimate length of uncompressed content by taking average compression ratios
401
+ * of compression type into account.
402
+ * @param {Response} response A Fetch API response object
403
+ * @param {boolean} lengthComputable Return wether content length was given in header.
404
+ * @returns {number}
405
+ */
406
+ function estimateContentLength(response, lengthComputable) {
407
+ if (!lengthComputable) {
408
+ // No content length available
409
+ return 0;
410
+ }
411
+
412
+ var compression = response.headers.get("Content-Encoding");
413
+ var contentLength = parseInt(response.headers.get("Content-Length"));
414
+
415
+ switch (compression) {
416
+ case "br":
417
+ return Math.round(contentLength * 5);
418
+ case "gzip":
419
+ return Math.round(contentLength * 4);
420
+ default:
421
+ return contentLength;
422
+ }
423
+ }
424
+
425
+ function readBodyWithProgress(response, onProgress, enableStreaming) {
426
+ var reader = response.body ? response.body.getReader() : undefined;
427
+ var lengthComputable = typeof response.headers.get('Content-Length') !== "undefined";
428
+ var estimatedContentLength = estimateContentLength(response, lengthComputable);
429
+ var body = new Uint8Array(estimatedContentLength);
430
+ var trailingChunks = [];
431
+ var receivedLength = 0;
432
+ var trailingChunksStart = 0;
433
+
434
+ if (!lengthComputable) {
435
+ console.warn("[UnityCache] Response is served without Content-Length header. Please reconfigure server to include valid Content-Length for better download performance.");
436
+ }
437
+
438
+ function readBody() {
439
+ if (typeof reader === "undefined") {
440
+ // Browser does not support streaming reader API
441
+ // Fallback to Respone.arrayBuffer()
442
+ return response.arrayBuffer().then(function (buffer) {
443
+ var body = new Uint8Array(buffer);
444
+ onProgress({
445
+ type: "progress",
446
+ response: response,
447
+ total: buffer.length,
448
+ loaded: 0,
449
+ lengthComputable: lengthComputable,
450
+ chunk: enableStreaming ? body : null
451
+ });
452
+
453
+ return body;
454
+ });
455
+ }
456
+
457
+ // Start reading memory chunks
458
+ return reader.read().then(function (result) {
459
+ if (result.done) {
460
+ return concatenateTrailingChunks();
461
+ }
462
+
463
+ if ((receivedLength + result.value.length) <= body.length) {
464
+ // Directly append chunk to body if enough memory was allocated
465
+ body.set(result.value, receivedLength);
466
+ trailingChunksStart = receivedLength + result.value.length;
467
+ } else {
468
+ // Store additional chunks in array to append later
469
+ trailingChunks.push(result.value);
470
+ }
471
+
472
+ receivedLength += result.value.length;
473
+ onProgress({
474
+ type: "progress",
475
+ response: response,
476
+ total: Math.max(estimatedContentLength, receivedLength),
477
+ loaded: receivedLength,
478
+ lengthComputable: lengthComputable,
479
+ chunk: enableStreaming ? result.value : null
480
+ });
481
+
482
+ return readBody();
483
+ });
484
+ }
485
+
486
+ function concatenateTrailingChunks() {
487
+ if (receivedLength === estimatedContentLength) {
488
+ return body;
489
+ }
490
+
491
+ if (receivedLength < estimatedContentLength) {
492
+ // Less data received than estimated, shrink body
493
+ return body.slice(0, receivedLength);
494
+ }
495
+
496
+ // More data received than estimated, create new larger body to prepend all additional chunks to the body
497
+ var newBody = new Uint8Array(receivedLength);
498
+ newBody.set(body, 0);
499
+ var position = trailingChunksStart;
500
+ for (var i = 0; i < trailingChunks.length; ++i) {
501
+ newBody.set(trailingChunks[i], position);
502
+ position += trailingChunks[i].length;
503
+ }
504
+
505
+ return newBody;
506
+ }
507
+
508
+ return readBody().then(function (parsedBody) {
509
+ onProgress({
510
+ type: "load",
511
+ response: response,
512
+ total: parsedBody.length,
513
+ loaded: parsedBody.length,
514
+ lengthComputable: lengthComputable,
515
+ chunk: null
516
+ });
517
+
518
+ response.parsedBody = parsedBody;
519
+ return response;
520
+ });
521
+ }
522
+
523
+ return readBodyWithProgress;
524
+ }();
525
+
526
+ Module.fetchWithProgress = function () {
527
+ function fetchWithProgress(resource, init) {
528
+ var onProgress = function () { };
529
+ if (init && init.onProgress) {
530
+ onProgress = init.onProgress;
531
+ }
532
+
533
+ return fetch(resource, init).then(function (response) {
534
+ return Module.readBodyWithProgress(response, onProgress, init.enableStreamingDownload);
535
+ });
536
+ }
537
+
538
+ return fetchWithProgress;
539
+ }();
540
+
541
+ /**
542
+ * @interface RequestMetaData
543
+ * An object with meta data for a request
544
+ *
545
+ * @property {string} url The url of a request
546
+ * @property {string} company The company name
547
+ * @property {string} product The product name
548
+ * @property {number} version The version of the build
549
+ * @property {number} size The company of the build
550
+ * @property {number} accessedAt Timestamp when request was last accessed (Unix timestamp format)
551
+ * @property {number} updatedAt Timestamp when request was last updated in the cache (Unix timestamp format)
552
+ */
553
+
554
+ /**
555
+ * @interface ResponseWithMetaData
556
+ * An object with a cached response and meta data
557
+ * @property {Response} response
558
+ * @property {RequestMetaData} metaData
559
+ */
560
+
561
+ Module.UnityCache = function () {
562
+ var UnityCacheDatabase = { name: "UnityCache", version: 4 };
563
+ var RequestMetaDataStore = { name: "RequestMetaDataStore", version: 1 };
564
+ var RequestStore = { name: "RequestStore", version: 1 };
565
+ var WebAssemblyStore = { name: "WebAssembly", version: 1 };
566
+ var indexedDB = window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
567
+
568
+ function log(message) {
569
+ console.log("[UnityCache] " + message);
570
+ }
571
+
572
+ /**
573
+ * A request cache that uses the browser Index DB to cache large requests
574
+ * @property {Promise<void>} isConnected
575
+ * @property {Cache} cache
576
+ */
577
+ function UnityCache() {
578
+ var self = this;
579
+
580
+ this.isConnected = this.connect().then(function () {
581
+ return self.cleanUpCache();
582
+ });
583
+
584
+ this.isConnected.catch(function (error) {
585
+ log("Error when initializing cache: " + error);
586
+ });
587
+ }
588
+
589
+ var instance = null;
590
+ /**
591
+ * Singleton accessor. Returns unity cache instance
592
+ * @returns {UnityCache}
593
+ */
594
+ UnityCache.getInstance = function () {
595
+ if (!instance) {
596
+ instance = new UnityCache();
597
+ }
598
+
599
+ return instance;
600
+ }
601
+
602
+ /**
603
+ * Destroy unity cache instance. Returns a promise that waits for the
604
+ * database connection to be closed.
605
+ * @returns {Promise<void>}
606
+ */
607
+ UnityCache.destroyInstance = function () {
608
+ if (!instance) {
609
+ return Promise.resolve();
610
+ }
611
+
612
+ return instance.close().then(function () {
613
+ instance = null;
614
+ });
615
+ }
616
+
617
+ /**
618
+ * Clear the unity cache.
619
+ * @returns {Promise<void>} A promise that resolves when the cache is cleared.
620
+ */
621
+ UnityCache.prototype.clearCache = function () {
622
+ var self = this;
623
+
624
+ function deleteCacheEntries(cacheKeys) {
625
+ if (cacheKeys.length === 0) {
626
+ return Promise.resolve();
627
+ }
628
+
629
+ var key = cacheKeys.pop();
630
+
631
+ return self.cache.delete(key).then(function () {
632
+ return deleteCacheEntries(cacheKeys);
633
+ });
634
+ }
635
+
636
+ return this.isConnected.then(function () {
637
+ return self.execute(RequestMetaDataStore.name, "clear", []);
638
+ }).then(function () {
639
+ return self.cache.keys();
640
+ }).then(function (keys) {
641
+ return deleteCacheEntries(keys)
642
+ });
643
+ }
644
+
645
+ /**
646
+ * Config for request meta data store
647
+ */
648
+ UnityCache.UnityCacheDatabase = UnityCacheDatabase;
649
+ UnityCache.RequestMetaDataStore = RequestMetaDataStore;
650
+ UnityCache.MaximumCacheSize = 1024 * 1024 * 1024; // 1 GB
651
+
652
+ /**
653
+ * Load a request response from cache
654
+ * @param {Request|string} request The fetch request
655
+ * @returns {Promise<ResponseWithMetaData|undefined>} A cached response with meta data for the request or undefined if request is not in cache.
656
+ */
657
+ UnityCache.prototype.loadRequest = function (request) {
658
+ var self = this;
659
+
660
+ return self.isConnected.then(function () {
661
+ return Promise.all([
662
+ self.cache.match(request),
663
+ self.loadRequestMetaData(request)
664
+ ]);
665
+ }).then(function (result) {
666
+ if (typeof result[0] === "undefined" || typeof result[1] === "undefined") {
667
+ return undefined;
668
+ }
669
+
670
+ return {
671
+ response: result[0],
672
+ metaData: result[1]
673
+ };
674
+ });
675
+ }
676
+
677
+ /**
678
+ * Load a request meta data from cache
679
+ * @param {Request|string} request The fetch request
680
+ * @returns {Promise<RequestMetaData>} Request meta data
681
+ */
682
+ UnityCache.prototype.loadRequestMetaData = function (request) {
683
+ var url = typeof request === "string" ? request : request.url;
684
+
685
+ return this.execute(RequestMetaDataStore.name, "get", [url]);
686
+ }
687
+
688
+ /**
689
+ * Update meta data of a request
690
+ * @param {RequestMetaData} metaData
691
+ * @returns {Promise<void>}
692
+ */
693
+ UnityCache.prototype.updateRequestMetaData = function (metaData) {
694
+ return this.execute(RequestMetaDataStore.name, "put", [metaData]);
695
+ }
696
+
697
+ /**
698
+ * Store request in cache
699
+ * @param {Request} request
700
+ * @param {Response} response
701
+ * @returns {Promise<void>}
702
+ */
703
+ UnityCache.prototype.storeRequest = function (request, response) {
704
+ var self = this;
705
+
706
+ return self.isConnected.then(function () {
707
+ return self.cache.put(request, response);
708
+ });
709
+ }
710
+
711
+ /**
712
+ * Close database and cache connection.
713
+ * @async
714
+ */
715
+ UnityCache.prototype.close = function () {
716
+ return this.isConnected.then(function () {
717
+ if (this.database) {
718
+ this.database.close();
719
+ this.database = null;
720
+ }
721
+
722
+ if (this.cache) {
723
+ this.cache = null;
724
+ }
725
+
726
+ }.bind(this));
727
+ }
728
+
729
+
730
+ /**
731
+ * Create a connection to Cache and IndexedDB for meta data storage
732
+ * @private
733
+ * @async
734
+ * @returns {Promise<void>} A Promise that is resolved when a connection to the IndexedDB and cache are established.
735
+ */
736
+ UnityCache.prototype.connect = function () {
737
+ var self = this;
738
+
739
+ if (typeof indexedDB === "undefined") {
740
+ return Promise.reject(new Error("Could not connect to cache: IndexedDB is not supported."));
741
+ }
742
+
743
+ if (typeof window.caches === "undefined") {
744
+ return Promise.reject(new Error("Could not connect to cache: Cache API is not supported."));
745
+ }
746
+
747
+ var isConnected = new Promise(function (resolve, reject) {
748
+ try {
749
+ // Workaround for WebKit bug 226547:
750
+ // On very first page load opening a connection to IndexedDB hangs without triggering onerror.
751
+ // Add a timeout that triggers the error handling code.
752
+ self.openDBTimeout = setTimeout(function () {
753
+ if (typeof self.database != "undefined") {
754
+ return;
755
+ }
756
+
757
+ reject(new Error("Could not connect to cache: Database timeout."));
758
+ }, 20000);
759
+
760
+ function clearOpenDBTimeout() {
761
+ if (!self.openDBTimeout) {
762
+ return;
763
+ }
764
+
765
+ clearTimeout(self.openDBTimeout);
766
+ self.openDBTimeout = null;
767
+ }
768
+
769
+ var openRequest = indexedDB.open(UnityCacheDatabase.name, UnityCacheDatabase.version);
770
+
771
+ openRequest.onupgradeneeded = self.upgradeDatabase.bind(self);
772
+
773
+ openRequest.onsuccess = function (e) {
774
+ clearOpenDBTimeout();
775
+ self.database = e.target.result;
776
+ resolve();
777
+ };
778
+
779
+ openRequest.onerror = function (error) {
780
+ clearOpenDBTimeout();
781
+ self.database = null;
782
+ reject(new Error("Could not connect to database."));
783
+ };
784
+ } catch (error) {
785
+ clearOpenDBTimeout();
786
+ self.database = null;
787
+ self.cache = null;
788
+ reject(new Error("Could not connect to cache: Could not connect to database."));
789
+ }
790
+ }).then(function () {
791
+ var cacheName = UnityCacheDatabase.name + "_" + Module.companyName + "_" + Module.productName;
792
+
793
+ return caches.open(cacheName);
794
+ }).then(function (cache) {
795
+ self.cache = cache;
796
+ });
797
+
798
+ return isConnected;
799
+ }
800
+
801
+ /**
802
+ * Upgrade object store if database is outdated
803
+ * @private
804
+ * @param {any} e Database upgrade event
805
+ */
806
+ UnityCache.prototype.upgradeDatabase = function (e) {
807
+ var database = e.target.result;
808
+
809
+ if (!database.objectStoreNames.contains(RequestMetaDataStore.name)) {
810
+ var objectStore = database.createObjectStore(RequestMetaDataStore.name, { keyPath: "url" });
811
+ ["accessedAt", "updatedAt"].forEach(function (index) { objectStore.createIndex(index, index); });
812
+ }
813
+
814
+ if (database.objectStoreNames.contains(RequestStore.name)) {
815
+ database.deleteObjectStore(RequestStore.name);
816
+ }
817
+
818
+ if (database.objectStoreNames.contains(WebAssemblyStore.name)) {
819
+ database.deleteObjectStore(WebAssemblyStore.name);
820
+ }
821
+ }
822
+
823
+ /**
824
+ * Execute an operation on the cache
825
+ * @private
826
+ * @param {string} store The name of the store to use
827
+ * @param {string} operation The operation to to execute on the cache
828
+ * @param {Array} parameters Parameters for the operation
829
+ * @returns {Promise} A promise to the cache entry
830
+ */
831
+ UnityCache.prototype.execute = function (store, operation, parameters) {
832
+ return this.isConnected.then(function () {
833
+ return new Promise(function (resolve, reject) {
834
+ try {
835
+ // Failure during initialization of database -> reject Promise
836
+ if (this.database === null) {
837
+ reject(new Error("indexedDB access denied"))
838
+ return;
839
+ }
840
+
841
+ // Create a transaction for the request
842
+ var accessMode = ["put", "delete", "clear"].indexOf(operation) != -1 ? "readwrite" : "readonly";
843
+ var transaction = this.database.transaction([store], accessMode)
844
+ var target = transaction.objectStore(store);
845
+ if (operation == "openKeyCursor") {
846
+ target = target.index(parameters[0]);
847
+ parameters = parameters.slice(1);
848
+ }
849
+
850
+ // Make a request to the database
851
+ var request = target[operation].apply(target, parameters);
852
+ request.onsuccess = function (e) {
853
+ resolve(e.target.result);
854
+ };
855
+ request.onerror = function (error) {
856
+ reject(error);
857
+ };
858
+ } catch (error) {
859
+ reject(error);
860
+ }
861
+ }.bind(this));
862
+ }.bind(this));
863
+ }
864
+
865
+ UnityCache.prototype.getMetaDataEntries = function () {
866
+ var self = this;
867
+ var cacheSize = 0;
868
+ var metaDataEntries = [];
869
+
870
+ return new Promise(function (resolve, reject) {
871
+ var transaction = self.database.transaction([RequestMetaDataStore.name], "readonly");
872
+ var target = transaction.objectStore(RequestMetaDataStore.name);
873
+ var request = target.openCursor();
874
+
875
+ request.onsuccess = function (event) {
876
+ var cursor = event.target.result;
877
+
878
+ if (cursor) {
879
+ cacheSize += cursor.value.size;
880
+ metaDataEntries.push(cursor.value);
881
+
882
+ cursor.continue();
883
+ } else {
884
+ resolve({
885
+ metaDataEntries: metaDataEntries,
886
+ cacheSize: cacheSize
887
+ });
888
+ }
889
+ };
890
+ request.onerror = function (error) {
891
+ reject(error);
892
+ };
893
+ });
894
+ }
895
+
896
+ /**
897
+ * Clean up cache by removing outdated entries.
898
+ * @private
899
+ * @returns {Promise<void>}
900
+ */
901
+ UnityCache.prototype.cleanUpCache = function () {
902
+ var self = this;
903
+
904
+ return this.getMetaDataEntries().then(function (result) {
905
+ var metaDataEntries = result.metaDataEntries;
906
+ var cacheSize = result.cacheSize;
907
+ var entriesToDelete = [];
908
+ var newMetaDataEntries = [];
909
+
910
+ // Remove cached entries with outdated product version
911
+ for (var i = 0; i < metaDataEntries.length; ++i) {
912
+ if (metaDataEntries[i].version == Module.productVersion) {
913
+ newMetaDataEntries.push(metaDataEntries[i]);
914
+ continue;
915
+ }
916
+
917
+ entriesToDelete.push(metaDataEntries[i]);
918
+ cacheSize -= metaDataEntries[i].size;
919
+ }
920
+
921
+ // Remove cache entries until cache size limit is met
922
+ newMetaDataEntries.sort(function (a,b) {
923
+ return a.accessedAt - b.accessedAt;
924
+ });
925
+
926
+ for (var i = 0; i < newMetaDataEntries.length; ++i) {
927
+ if (cacheSize < UnityCache.MaximumCacheSize) {
928
+ break;
929
+ }
930
+
931
+ entriesToDelete.push(newMetaDataEntries[i]);
932
+ cacheSize -= newMetaDataEntries[i].size;
933
+ }
934
+
935
+ function deleteMetaDataEntry(url) {
936
+ return new Promise(function (resolve, reject) {
937
+ var transaction = self.database.transaction([RequestMetaDataStore.name], "readwrite");
938
+ var target = transaction.objectStore(RequestMetaDataStore.name);
939
+ target.delete(url);
940
+
941
+ transaction.oncomplete = resolve;
942
+ transaction.onerror = reject;
943
+ });
944
+ }
945
+
946
+ function deleteEntries() {
947
+ if (entriesToDelete.length === 0) {
948
+ return Promise.resolve();
949
+ }
950
+
951
+ var entryToDelete = entriesToDelete.pop();
952
+ return self.cache.delete(entryToDelete.url).then(function (deleted) {
953
+ if (deleted) {
954
+ return deleteMetaDataEntry(entryToDelete.url);
955
+ }
956
+ }).then(function () {
957
+ return deleteEntries();
958
+ });
959
+ }
960
+
961
+ return deleteEntries();
962
+ });
963
+ }
964
+
965
+ return UnityCache;
966
+ }();
967
+ Module.cachedFetch = function () {
968
+ var UnityCache = Module.UnityCache;
969
+ var fetchWithProgress = Module.fetchWithProgress;
970
+ var readBodyWithProgress = Module.readBodyWithProgress;
971
+
972
+ function log(message) {
973
+ console.log("[UnityCache] " + message);
974
+ }
975
+
976
+ function resolveURL(url) {
977
+ resolveURL.link = resolveURL.link || document.createElement("a");
978
+ resolveURL.link.href = url;
979
+ return resolveURL.link.href;
980
+ }
981
+
982
+ function isCrossOriginURL(url) {
983
+ var originMatch = window.location.href.match(/^[a-z]+:\/\/[^\/]+/);
984
+ return !originMatch || url.lastIndexOf(originMatch[0], 0);
985
+ }
986
+
987
+ function isCacheEnabled(url, init) {
988
+ if (init && init.method && init.method !== "GET") {
989
+ return false;
990
+ }
991
+
992
+ if (init && ["must-revalidate", "immutable"].indexOf(init.control) == -1) {
993
+ return false;
994
+ }
995
+
996
+ if (!url.match("^https?:\/\/")) {
997
+ return false;
998
+ }
999
+
1000
+ return true;
1001
+ }
1002
+
1003
+ function cachedFetch(resource, init) {
1004
+ var unityCache = UnityCache.getInstance();
1005
+ var url = resolveURL((typeof resource === "string") ? resource : resource.url);
1006
+ var cache = { enabled: isCacheEnabled(url, init) };
1007
+ if (init) {
1008
+ cache.control = init.control;
1009
+ cache.companyName = init.companyName;
1010
+ cache.productName = init.productName;
1011
+ cache.productVersion = init.productVersion;
1012
+ }
1013
+ cache.revalidated = false;
1014
+ cache.metaData = {
1015
+ url: url,
1016
+ accessedAt: Date.now(),
1017
+ version: cache.productVersion
1018
+ };
1019
+ cache.response = null;
1020
+
1021
+ function fetchAndStoreInCache(resource, init) {
1022
+ return fetch(resource, init).then(function (response) {
1023
+ if (!cache.enabled || cache.revalidated) {
1024
+ return response;
1025
+ }
1026
+
1027
+ if (response.status === 304) {
1028
+ // Cached response is still valid. Set revalidated flag and return cached response
1029
+ cache.revalidated = true;
1030
+
1031
+ unityCache.updateRequestMetaData(cache.metaData).then(function () {
1032
+ log("'" + cache.metaData.url + "' successfully revalidated and served from the indexedDB cache");
1033
+ }).catch(function (error) {
1034
+ log("'" + cache.metaData.url + "' successfully revalidated but not stored in the indexedDB cache due to the error: " + error);
1035
+ });
1036
+
1037
+ return readBodyWithProgress(cache.response, init.onProgress, init.enableStreamingDownload);
1038
+ } else if (response.status == 200) {
1039
+ // New response -> Store it and cache and return it
1040
+ cache.response = response;
1041
+ cache.metaData.updatedAt = cache.metaData.accessedAt;
1042
+ cache.revalidated = true;
1043
+ var clonedResponse = response.clone();
1044
+
1045
+ return readBodyWithProgress(response, init.onProgress, init.enableStreamingDownload).then(function (response) {
1046
+ // Update cached request and meta data
1047
+ cache.metaData.size = response.parsedBody.length;
1048
+ Promise.all([
1049
+ unityCache.storeRequest(resource, clonedResponse),
1050
+ unityCache.updateRequestMetaData(cache.metaData)
1051
+ ]).then(function () {
1052
+ log("'" + url + "' successfully downloaded and stored in the indexedDB cache");
1053
+ }).catch(function (error) {
1054
+ log("'" + url + "' successfully downloaded but not stored in the indexedDB cache due to the error: " + error);
1055
+ });
1056
+
1057
+ return response;
1058
+ });
1059
+ } else {
1060
+ // Request failed
1061
+ log("'" + url + "' request failed with status: " + response.status + " " + response.statusText);
1062
+ }
1063
+
1064
+ return readBodyWithProgress(response, init.onProgress, init.enableStreamingDownload);
1065
+ });
1066
+ }
1067
+
1068
+ // Use fetch directly if request can't be cached
1069
+ if (!cache.enabled) {
1070
+ return fetchWithProgress(resource, init);
1071
+ }
1072
+
1073
+ return unityCache.loadRequest(url).then(function (result) {
1074
+ // Fetch resource and store it in cache if not present or outdated version
1075
+ if (!result) {
1076
+ return fetchAndStoreInCache(resource, init);
1077
+ }
1078
+
1079
+ var response = result.response;
1080
+ var metaData = result.metaData;
1081
+ cache.response = response;
1082
+ cache.metaData.size = metaData.size;
1083
+ cache.metaData.updatedAt = metaData.updatedAt;
1084
+
1085
+ if (cache.control == "immutable") {
1086
+ cache.revalidated = true;
1087
+ unityCache.updateRequestMetaData(metaData).then(function () {
1088
+ log("'" + cache.metaData.url + "' served from the indexedDB cache without revalidation");
1089
+ });
1090
+
1091
+ return readBodyWithProgress(response, init.onProgress, init.enableStreamingDownload);
1092
+ } else if (isCrossOriginURL(url) && (response.headers.get("Last-Modified") || response.headers.get("ETag"))) {
1093
+ return fetch(url, { method: "HEAD" }).then(function (headResult) {
1094
+ cache.revalidated = ["Last-Modified", "ETag"].every(function (header) {
1095
+ return !response.headers.get(header) || response.headers.get(header) == headResult.headers.get(header);
1096
+ });
1097
+ if (cache.revalidated) {
1098
+ unityCache.updateRequestMetaData(metaData).then(function () {
1099
+ log("'" + cache.metaData.url + "' successfully revalidated and served from the indexedDB cache");
1100
+ });
1101
+
1102
+ return readBodyWithProgress(cache.response, init.onProgress, init.enableStreamingDownload);
1103
+ } else {
1104
+ return fetchAndStoreInCache(resource, init);
1105
+ }
1106
+ });
1107
+ } else {
1108
+ init = init || {};
1109
+ var requestHeaders = init.headers || {};
1110
+ init.headers = requestHeaders;
1111
+ if (response.headers.get("Last-Modified")) {
1112
+ requestHeaders["If-Modified-Since"] = response.headers.get("Last-Modified");
1113
+ requestHeaders["Cache-Control"] = "no-cache";
1114
+ } else if (response.headers.get("ETag")) {
1115
+ requestHeaders["If-None-Match"] = response.headers.get("ETag");
1116
+ requestHeaders["Cache-Control"] = "no-cache";
1117
+ }
1118
+
1119
+ return fetchAndStoreInCache(resource, init);
1120
+ }
1121
+ }).catch(function (error) {
1122
+ // Fallback to regular fetch if and IndexDB error occurs
1123
+ log("Failed to load '" + cache.metaData.url + "' from indexedDB cache due to the error: " + error);
1124
+ return fetchWithProgress(resource, init);
1125
+ });
1126
+ }
1127
+
1128
+ return cachedFetch;
1129
+ }();
1130
+
1131
+
1132
+ function downloadBinary(urlId) {
1133
+ progressUpdate(urlId);
1134
+ var cacheControl = Module.cacheControl(Module[urlId]);
1135
+ var fetchImpl = Module.companyName && Module.productName ? Module.cachedFetch : Module.fetchWithProgress;
1136
+ var url = Module[urlId];
1137
+ var mode = /file:\/\//.exec(url) ? "same-origin" : undefined;
1138
+
1139
+ var request = fetchImpl(Module[urlId], {
1140
+ method: "GET",
1141
+ companyName: Module.companyName,
1142
+ productName: Module.productName,
1143
+ productVersion: Module.productVersion,
1144
+ control: cacheControl,
1145
+ mode: mode,
1146
+ onProgress: function (event) {
1147
+ progressUpdate(urlId, event);
1148
+ }
1149
+ });
1150
+
1151
+ return request.then(function (response) {
1152
+ return response.parsedBody;
1153
+ }).catch(function (e) {
1154
+ var error = 'Failed to download file ' + Module[urlId];
1155
+ if (location.protocol == 'file:') {
1156
+ showBanner(error + '. Loading web pages via a file:// URL without a web server is not supported by this browser. Please use a local development web server to host Unity content, or use the Unity Build and Run option.', 'error');
1157
+ } else {
1158
+ console.error(error);
1159
+ }
1160
+ });
1161
+ }
1162
+
1163
+ function downloadFramework() {
1164
+ return new Promise(function (resolve, reject) {
1165
+ var script = document.createElement("script");
1166
+ script.src = Module.frameworkUrl;
1167
+ script.onload = function () {
1168
+ // Adding the framework.js script to DOM created a global
1169
+ // 'unityFramework' variable that should be considered internal.
1170
+ // If not, then we have received a malformed file.
1171
+ if (typeof unityFramework === 'undefined' || !unityFramework) {
1172
+ var compressions = [['br', 'br'], ['gz', 'gzip']];
1173
+ for(var i in compressions) {
1174
+ var compression = compressions[i];
1175
+ if (Module.frameworkUrl.endsWith('.' + compression[0])) {
1176
+ var error = 'Unable to parse ' + Module.frameworkUrl + '!';
1177
+ if (location.protocol == 'file:') {
1178
+ showBanner(error + ' Loading pre-compressed (brotli or gzip) content via a file:// URL without a web server is not supported by this browser. Please use a local development web server to host compressed Unity content, or use the Unity Build and Run option.', 'error');
1179
+ return;
1180
+ }
1181
+ error += ' This can happen if build compression was enabled but web server hosting the content was misconfigured to not serve the file with HTTP Response Header "Content-Encoding: ' + compression[1] + '" present. Check browser Console and Devtools Network tab to debug.';
1182
+ if (compression[0] == 'br') {
1183
+ if (location.protocol == 'http:') {
1184
+ var migrationHelp = ['localhost', '127.0.0.1'].indexOf(location.hostname) != -1 ? '' : 'Migrate your server to use HTTPS.'
1185
+ if (/Firefox/.test(navigator.userAgent)) error = 'Unable to parse ' + Module.frameworkUrl + '!<br>If using custom web server, verify that web server is sending .br files with HTTP Response Header "Content-Encoding: br". Brotli compression may not be supported in Firefox over HTTP connections. ' + migrationHelp + ' See <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1670675">https://bugzilla.mozilla.org/show_bug.cgi?id=1670675</a> for more information.';
1186
+ else error = 'Unable to parse ' + Module.frameworkUrl + '!<br>If using custom web server, verify that web server is sending .br files with HTTP Response Header "Content-Encoding: br". Brotli compression may not be supported over HTTP connections. Migrate your server to use HTTPS.';
1187
+ }
1188
+ }
1189
+ showBanner(error, 'error');
1190
+ return;
1191
+ }
1192
+ };
1193
+ showBanner('Unable to parse ' + Module.frameworkUrl + '! The file is corrupt, or compression was misconfigured? (check Content-Encoding HTTP Response Header on web server)', 'error');
1194
+ }
1195
+
1196
+ // Capture the variable to local scope and clear it from global
1197
+ // scope so that JS garbage collection can take place on
1198
+ // application quit.
1199
+ var fw = unityFramework;
1200
+ unityFramework = null;
1201
+ // Also ensure this function will not hold any JS scope
1202
+ // references to prevent JS garbage collection.
1203
+ script.onload = null;
1204
+ resolve(fw);
1205
+ }
1206
+ script.onerror = function(e) {
1207
+ showBanner('Unable to load file ' + Module.frameworkUrl + '! Check that the file exists on the remote server. (also check browser Console and Devtools Network tab to debug)', 'error');
1208
+ }
1209
+ document.body.appendChild(script);
1210
+ Module.deinitializers.push(function() {
1211
+ document.body.removeChild(script);
1212
+ });
1213
+ });
1214
+ }
1215
+
1216
+ function loadBuild() {
1217
+ downloadFramework().then(function (unityFramework) {
1218
+ unityFramework(Module);
1219
+ });
1220
+
1221
+ var dataPromise = downloadBinary("dataUrl");
1222
+ Module.preRun.push(function () {
1223
+ Module.addRunDependency("dataUrl");
1224
+ dataPromise.then(function (data) {
1225
+ var view = new DataView(data.buffer, data.byteOffset, data.byteLength);
1226
+ var pos = 0;
1227
+ var prefix = "UnityWebData1.0\0";
1228
+ if (!String.fromCharCode.apply(null, data.subarray(pos, pos + prefix.length)) == prefix)
1229
+ throw "unknown data format";
1230
+ pos += prefix.length;
1231
+ var headerSize = view.getUint32(pos, true); pos += 4;
1232
+ while (pos < headerSize) {
1233
+ var offset = view.getUint32(pos, true); pos += 4;
1234
+ var size = view.getUint32(pos, true); pos += 4;
1235
+ var pathLength = view.getUint32(pos, true); pos += 4;
1236
+ var path = String.fromCharCode.apply(null, data.subarray(pos, pos + pathLength)); pos += pathLength;
1237
+ for (var folder = 0, folderNext = path.indexOf("/", folder) + 1 ; folderNext > 0; folder = folderNext, folderNext = path.indexOf("/", folder) + 1)
1238
+ Module.FS_createPath(path.substring(0, folder), path.substring(folder, folderNext - 1), true, true);
1239
+ Module.FS_createDataFile(path, null, data.subarray(offset, offset + size), true, true, true);
1240
+ }
1241
+ Module.removeRunDependency("dataUrl");
1242
+ });
1243
+ });
1244
+ }
1245
+
1246
+ return new Promise(function (resolve, reject) {
1247
+ if (!Module.SystemInfo.hasWebGL) {
1248
+ reject("Your browser does not support WebGL.");
1249
+ } else if (Module.SystemInfo.hasWebGL == 1) {
1250
+ var msg = "Your browser does not support graphics API \"WebGL 2\" which is required for this content.";
1251
+ if (Module.SystemInfo.browser == 'Safari' && parseInt(Module.SystemInfo.browserVersion) < 15) {
1252
+ if (Module.SystemInfo.mobile || navigator.maxTouchPoints > 1)
1253
+ msg += "\nUpgrade to iOS 15 or later.";
1254
+ else
1255
+ msg += "\nUpgrade to Safari 15 or later.";
1256
+ }
1257
+ reject(msg);
1258
+ } else if (!Module.SystemInfo.hasWasm) {
1259
+ reject("Your browser does not support WebAssembly.");
1260
+ } else {
1261
+ Module.startupErrorHandler = reject;
1262
+ onProgress(0);
1263
+ Module.postRun.push(function () {
1264
+ onProgress(1);
1265
+ delete Module.startupErrorHandler;
1266
+ resolve(unityInstance);
1267
+ });
1268
+ loadBuild();
1269
+ }
1270
+ });
1271
+ }
Build/202408130439.wasm ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0e12099127ef93f8f17200f6067eddfc976941ab8efccb22a8fbc9199b1a026f
3
+ size 113467850
StreamingAssets/UTJ/FrameCapturer/License.txt ADDED
@@ -0,0 +1,274 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ FrameCapturer:
3
+ https://github.com/unity3d-jp/FrameCapturer
4
+
5
+ Copyright (C) 2015-2017 Unity Technologies Japan, G.K.
6
+
7
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
+
9
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
10
+
11
+ --------------------------------------------------------------------------
12
+
13
+ libyuv:
14
+ https://code.google.com/p/libyuv/
15
+
16
+ Copyright 2011 The LibYuv Project Authors. All rights reserved.
17
+
18
+ Redistribution and use in source and binary forms, with or without
19
+ modification, are permitted provided that the following conditions are
20
+ met:
21
+
22
+ * Redistributions of source code must retain the above copyright
23
+ notice, this list of conditions and the following disclaimer.
24
+
25
+ * Redistributions in binary form must reproduce the above copyright
26
+ notice, this list of conditions and the following disclaimer in
27
+ the documentation and/or other materials provided with the
28
+ distribution.
29
+
30
+ * Neither the name of Google nor the names of its contributors may
31
+ be used to endorse or promote products derived from this software
32
+ without specific prior written permission.
33
+
34
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
35
+ "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
36
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
37
+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
38
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
39
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
40
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
41
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
42
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
43
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
44
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
45
+
46
+ --------------------------------------------------------------------------
47
+
48
+ GIF Writer:
49
+ http://www.jonolick.com/home/gif-writer
50
+
51
+ (Public Domain)
52
+
53
+ --------------------------------------------------------------------------
54
+
55
+ OpenEXR:
56
+ http://www.openexr.com/
57
+
58
+ Copyright (c) 2006, Industrial Light & Magic, a division of Lucasfilm
59
+ Entertainment Company Ltd. Portions contributed and copyright held by
60
+ others as indicated. All rights reserved.
61
+
62
+ Redistribution and use in source and binary forms, with or without
63
+ modification, are permitted provided that the following conditions are
64
+ met:
65
+
66
+ * Redistributions of source code must retain the above
67
+ copyright notice, this list of conditions and the following
68
+ disclaimer.
69
+
70
+ * Redistributions in binary form must reproduce the above
71
+ copyright notice, this list of conditions and the following
72
+ disclaimer in the documentation and/or other materials provided with
73
+ the distribution.
74
+
75
+ * Neither the name of Industrial Light & Magic nor the names of
76
+ any other contributors to this software may be used to endorse or
77
+ promote products derived from this software without specific prior
78
+ written permission.
79
+
80
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
81
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
82
+ THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
83
+ PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
84
+ CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
85
+ EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
86
+ PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
87
+ PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
88
+ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
89
+ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
90
+ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
91
+
92
+ --------------------------------------------------------------------------
93
+
94
+ zlib:
95
+ http://www.zlib.net/
96
+
97
+ (C) 1995-2013 Jean-loup Gailly and Mark Adler
98
+
99
+ This software is provided 'as-is', without any express or implied
100
+ warranty. In no event will the authors be held liable for any damages
101
+ arising from the use of this software.
102
+
103
+ Permission is granted to anyone to use this software for any purpose,
104
+ including commercial applications, and to alter it and redistribute it
105
+ freely, subject to the following restrictions:
106
+
107
+ 1. The origin of this software must not be misrepresented; you must not
108
+ claim that you wrote the original software. If you use this software
109
+ in a product, an acknowledgment in the product documentation would be
110
+ appreciated but is not required.
111
+ 2. Altered source versions must be plainly marked as such, and must not be
112
+ misrepresented as being the original software.
113
+ 3. This notice may not be removed or altered from any source distribution.
114
+
115
+ Jean-loup Gailly Mark Adler
116
117
+
118
+ --------------------------------------------------------------------------
119
+
120
+ libpng:
121
+ http://www.libpng.org/
122
+
123
+ libpng versions 1.0.7, July 1, 2000, through 1.6.21, January 15, 2016, are
124
+ Copyright (c) 2000-2002, 2004, 2006-2016 Glenn Randers-Pehrson, are
125
+ derived from libpng-1.0.6, and are distributed according to the same
126
+ disclaimer and license as libpng-1.0.6 with the following individuals
127
+ added to the list of Contributing Authors:
128
+
129
+ Simon-Pierre Cadieux
130
+ Eric S. Raymond
131
+ Mans Rullgard
132
+ Cosmin Truta
133
+ Gilles Vollant
134
+ James Yu
135
+
136
+ and with the following additions to the disclaimer:
137
+
138
+ There is no warranty against interference with your enjoyment of the
139
+ library or against infringement. There is no warranty that our
140
+ efforts or the library will fulfill any of your particular purposes
141
+ or needs. This library is provided with all faults, and the entire
142
+ risk of satisfactory quality, performance, accuracy, and effort is with
143
+ the user.
144
+
145
+ libpng versions 0.97, January 1998, through 1.0.6, March 20, 2000, are
146
+ Copyright (c) 1998-2000 Glenn Randers-Pehrson, are derived from
147
+ libpng-0.96, and are distributed according to the same disclaimer and
148
+ license as libpng-0.96, with the following individuals added to the list
149
+ of Contributing Authors:
150
+
151
+ Tom Lane
152
+ Glenn Randers-Pehrson
153
+ Willem van Schaik
154
+
155
+ libpng versions 0.89, June 1996, through 0.96, May 1997, are
156
+ Copyright (c) 1996-1997 Andreas Dilger, are derived from libpng-0.88,
157
+ and are distributed according to the same disclaimer and license as
158
+ libpng-0.88, with the following individuals added to the list of
159
+ Contributing Authors:
160
+
161
+ John Bowler
162
+ Kevin Bracey
163
+ Sam Bushell
164
+ Magnus Holmgren
165
+ Greg Roelofs
166
+ Tom Tanner
167
+
168
+ libpng versions 0.5, May 1995, through 0.88, January 1996, are
169
+ Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
170
+
171
+ For the purposes of this copyright and license, "Contributing Authors"
172
+ is defined as the following set of individuals:
173
+
174
+ Andreas Dilger
175
+ Dave Martindale
176
+ Guy Eric Schalnat
177
+ Paul Schmidt
178
+ Tim Wegner
179
+
180
+ The PNG Reference Library is supplied "AS IS". The Contributing Authors
181
+ and Group 42, Inc. disclaim all warranties, expressed or implied,
182
+ including, without limitation, the warranties of merchantability and of
183
+ fitness for any purpose. The Contributing Authors and Group 42, Inc.
184
+ assume no liability for direct, indirect, incidental, special, exemplary,
185
+ or consequential damages, which may result from the use of the PNG
186
+ Reference Library, even if advised of the possibility of such damage.
187
+
188
+ Permission is hereby granted to use, copy, modify, and distribute this
189
+ source code, or portions hereof, for any purpose, without fee, subject
190
+ to the following restrictions:
191
+
192
+ 1. The origin of this source code must not be misrepresented.
193
+
194
+ 2. Altered versions must be plainly marked as such and must not
195
+ be misrepresented as being the original source.
196
+
197
+ 3. This Copyright notice may not be removed or altered from any
198
+ source or altered source distribution.
199
+
200
+ The Contributing Authors and Group 42, Inc. specifically permit, without
201
+ fee, and encourage the use of this source code as a component to
202
+ supporting the PNG file format in commercial products. If you use this
203
+ source code in a product, acknowledgment is not required but would be
204
+ appreciated.
205
+
206
+ --------------------------------------------------------------------------
207
+
208
+ libwebm / libvpx:
209
+ https://www.webmproject.org/
210
+
211
+ Copyright (c) 2010, The WebM Project authors. All rights reserved.
212
+
213
+ Redistribution and use in source and binary forms, with or without
214
+ modification, are permitted provided that the following conditions are
215
+ met:
216
+
217
+ * Redistributions of source code must retain the above copyright
218
+ notice, this list of conditions and the following disclaimer.
219
+
220
+ * Redistributions in binary form must reproduce the above copyright
221
+ notice, this list of conditions and the following disclaimer in
222
+ the documentation and/or other materials provided with the
223
+ distribution.
224
+
225
+ * Neither the name of Google, nor the WebM Project, nor the names
226
+ of its contributors may be used to endorse or promote products
227
+ derived from this software without specific prior written
228
+ permission.
229
+
230
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
231
+ "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
232
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
233
+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
234
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
235
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
236
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
237
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
238
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
239
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
240
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
241
+
242
+ --------------------------------------------------------------------------
243
+
244
+ libogg / libvorbis:
245
+ https://www.xiph.org/downloads/
246
+
247
+ Copyright (c) 2002, Xiph.org Foundation
248
+
249
+ Redistribution and use in source and binary forms, with or without
250
+ modification, are permitted provided that the following conditions
251
+ are met:
252
+
253
+ - Redistributions of source code must retain the above copyright
254
+ notice, this list of conditions and the following disclaimer.
255
+
256
+ - Redistributions in binary form must reproduce the above copyright
257
+ notice, this list of conditions and the following disclaimer in the
258
+ documentation and/or other materials provided with the distribution.
259
+
260
+ - Neither the name of the Xiph.org Foundation nor the names of its
261
+ contributors may be used to endorse or promote products derived from
262
+ this software without specific prior written permission.
263
+
264
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
265
+ ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
266
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
267
+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION
268
+ OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
269
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
270
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
271
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
272
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
273
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
274
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
StreamingAssets/aa/WebGL/ac0e23d44a7dd08213ca90b2d5691c52_unitybuiltinshaders_621a4e9ee78e345eca15e91284c8531d.bundle ADDED
Binary file (19.7 kB). View file
 
StreamingAssets/aa/WebGL/defaultlocalgroup_assets_all_1d77e30cf80b0da8b5c23fbeabf9d618.bundle ADDED
Binary file (18.8 kB). View file
 
StreamingAssets/aa/WebGL/lowpolyinterior2_assets_all_92e55feb430f06d5d25422f36914075a.bundle ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:08415d07025caa37d932748fcfddbf5dc75d68e48346bba7bed3c351d4c76dfa
3
+ size 34595749
StreamingAssets/aa/WebGL/lowpolyinterior_assets_all_dac3ef8b16666c3b3ee95e6d9bffb1b8.bundle ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5b3584da8f9deced27097c10eeada85823ba8aa76fed87266ed393df7c13c55a
3
+ size 5885631
StreamingAssets/aa/WebGL/worldmaterialsfree_assets_all_abfeef79148fe6d5779541a3bca55136.bundle ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e939c9f7a7e3d57c6e06589840fba10c0d733cb8ae6e4b032502218bfa233eec
3
+ size 13495324
StreamingAssets/aa/catalog.json CHANGED
The diff for this file is too large to render. See raw diff
 
StreamingAssets/aa/settings.json CHANGED
@@ -1 +1 @@
1
- {"m_buildTarget":"WebGL","m_SettingsHash":"6c5b529a4eae02ee57053a61d7271cf7","m_CatalogLocations":[{"m_Keys":["AddressablesMainContentCatalog"],"m_InternalId":"{UnityEngine.AddressableAssets.Addressables.RuntimePath}/catalog.json","m_Provider":"UnityEngine.AddressableAssets.ResourceProviders.ContentCatalogProvider","m_Dependencies":[],"m_ResourceType":{"m_AssemblyName":"Unity.Addressables, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null","m_ClassName":"UnityEngine.AddressableAssets.ResourceLocators.ContentCatalogData"},"SerializedData":[]}],"m_ProfileEvents":false,"m_LogResourceManagerExceptions":true,"m_ExtraInitializationData":[],"m_DisableCatalogUpdateOnStart":false,"m_IsLocalCatalogInBundle":false,"m_CertificateHandlerType":{"m_AssemblyName":"","m_ClassName":""},"m_AddressablesVersion":"1.21.10","m_maxConcurrentWebRequests":3,"m_CatalogRequestsTimeout":0}
 
1
+ {"m_buildTarget":"WebGL","m_SettingsHash":"6c5b529a4eae02ee57053a61d7271cf7","m_CatalogLocations":[{"m_Keys":["AddressablesMainContentCatalog"],"m_InternalId":"{UnityEngine.AddressableAssets.Addressables.RuntimePath}/catalog.json","m_Provider":"UnityEngine.AddressableAssets.ResourceProviders.ContentCatalogProvider","m_Dependencies":[],"m_ResourceType":{"m_AssemblyName":"Unity.Addressables, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null","m_ClassName":"UnityEngine.AddressableAssets.ResourceLocators.ContentCatalogData"},"SerializedData":[7,76,85,110,105,116,121,46,82,101,115,111,117,114,99,101,77,97,110,97,103,101,114,44,32,86,101,114,115,105,111,110,61,48,46,48,46,48,46,48,44,32,67,117,108,116,117,114,101,61,110,101,117,116,114,97,108,44,32,80,117,98,108,105,99,75,101,121,84,111,107,101,110,61,110,117,108,108,75,85,110,105,116,121,69,110,103,105,110,101,46,82,101,115,111,117,114,99,101,77,97,110,97,103,101,109,101,110,116,46,82,101,115,111,117,114,99,101,80,114,111,118,105,100,101,114,115,46,80,114,111,118,105,100,101,114,76,111,97,100,82,101,113,117,101,115,116,79,112,116,105,111,110,115,50,0,0,0,123,0,34,0,109,0,95,0,73,0,103,0,110,0,111,0,114,0,101,0,70,0,97,0,105,0,108,0,117,0,114,0,101,0,115,0,34,0,58,0,116,0,114,0,117,0,101,0,125,0]}],"m_ProfileEvents":false,"m_LogResourceManagerExceptions":true,"m_ExtraInitializationData":[],"m_DisableCatalogUpdateOnStart":false,"m_IsLocalCatalogInBundle":false,"m_CertificateHandlerType":{"m_AssemblyName":"","m_ClassName":""},"m_AddressablesVersion":"1.21.19","m_maxConcurrentWebRequests":3,"m_CatalogRequestsTimeout":0}
index.html CHANGED
@@ -25,11 +25,11 @@
25
  <script>
26
  const hideFullScreenButton = "";
27
  const buildUrl = "Build";
28
- const loaderUrl = buildUrl + "/202405071939.loader.js";
29
  const config = {
30
- dataUrl: buildUrl + "/202405071939.data",
31
- frameworkUrl: buildUrl + "/202405071939.framework.js",
32
- codeUrl: buildUrl + "/202405071939.wasm",
33
  streamingAssetsUrl: "StreamingAssets",
34
  companyName: "LEGENT",
35
  productName: "LEGENT",
@@ -79,7 +79,7 @@
79
  fullscreenButton.style.display = "";
80
  }
81
  fullscreenButton.onclick = () => {
82
- unityInstance.SetFullscreen(1);
83
  };
84
  }
85
  }).catch((message) => {
 
25
  <script>
26
  const hideFullScreenButton = "";
27
  const buildUrl = "Build";
28
+ const loaderUrl = buildUrl + "/202408130439.loader.js";
29
  const config = {
30
+ dataUrl: buildUrl + "/202408130439.data",
31
+ frameworkUrl: buildUrl + "/202408130439.framework.js",
32
+ codeUrl: buildUrl + "/202408130439.wasm",
33
  streamingAssetsUrl: "StreamingAssets",
34
  companyName: "LEGENT",
35
  productName: "LEGENT",
 
79
  fullscreenButton.style.display = "";
80
  }
81
  fullscreenButton.onclick = () => {
82
+ document.makeFullscreen('unity-container');
83
  };
84
  }
85
  }).catch((message) => {