@woosh/meep-engine 2.43.12 → 2.43.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/engine/EngineHarness.js
CHANGED
|
@@ -88,10 +88,12 @@ export class EngineHarness {
|
|
|
88
88
|
|
|
89
89
|
/**
|
|
90
90
|
* @param {(config:EngineConfiguration,engine:Engine)=>*} configuration
|
|
91
|
+
* @param {boolean} [enable_localization] Whether or not to load localization data
|
|
91
92
|
* @returns {Promise<Engine>}
|
|
92
93
|
*/
|
|
93
94
|
initialize({
|
|
94
|
-
configuration = noop
|
|
95
|
+
configuration = noop,
|
|
96
|
+
enable_localization = false,
|
|
95
97
|
} = {}) {
|
|
96
98
|
|
|
97
99
|
if (this.p !== null) {
|
|
@@ -113,7 +115,13 @@ export class EngineHarness {
|
|
|
113
115
|
|
|
114
116
|
await engine.start();
|
|
115
117
|
|
|
116
|
-
|
|
118
|
+
if (enable_localization) {
|
|
119
|
+
try {
|
|
120
|
+
await setLocale(engine);
|
|
121
|
+
} catch (e) {
|
|
122
|
+
console.warn('Failed to load localization:', e);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
117
125
|
|
|
118
126
|
engine.sceneManager.create("test");
|
|
119
127
|
engine.sceneManager.set("test");
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"productName": "Meep",
|
|
6
6
|
"description": "production-ready JavaScript game engine based on Entity Component System Architecture",
|
|
7
7
|
"author": "Alexander Goldring",
|
|
8
|
-
"version": "2.43.
|
|
8
|
+
"version": "2.43.13",
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"gl-matrix": "3.4.3",
|
|
11
11
|
"fast-levenshtein": "2.0.6",
|