@needle-tools/engine 3.5.5-alpha → 3.5.5-alpha.1
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/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,9 @@ All notable changes to this package will be documented in this file.
|
|
|
4
4
|
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
|
5
5
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
6
6
|
|
|
7
|
+
## [3.5.5-alpha.1] - 2023-05-11
|
|
8
|
+
- Fix: declare missing defines for pre-bundled engine
|
|
9
|
+
|
|
7
10
|
## [3.5.5-alpha] - 2023-05-11
|
|
8
11
|
- Add: getWorldDirection
|
|
9
12
|
- Add: needle.config.json `build.copy = []` to copy files on build from arbitrary locations into the dist folder for example:
|
package/dist/needle-engine.js
CHANGED
|
@@ -435,7 +435,7 @@ function UH(i, A) {
|
|
|
435
435
|
}
|
|
436
436
|
return e.title = "Open the browser console (F12) for more information", e.innerHTML = A, e;
|
|
437
437
|
}
|
|
438
|
-
const RJ =
|
|
438
|
+
const RJ = null, FH = { version: null }.generator, Nn = "needle_isActiveInHierarchy", QB = "builtin_components", yu = "needle_editor_guid";
|
|
439
439
|
/**
|
|
440
440
|
* @license
|
|
441
441
|
* Copyright 2010-2022 Three.js Authors
|
|
@@ -83920,8 +83920,8 @@ const qoA = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty(
|
|
|
83920
83920
|
version: rH
|
|
83921
83921
|
}, Symbol.toStringTag, { value: "Module" })), BI = EA("debugphysics"), bS = EA("debugphysicscolliders"), LS = EA("debugcollisions"), boA = EA("showcolliders"), Fo = Symbol("needle component"), HI = Symbol("physics body"), LoA = Symbol("rigidbody");
|
|
83922
83922
|
let ZC;
|
|
83923
|
-
|
|
83924
|
-
BI && console.log("Register rapier physics backend"), i.context.physics.engine = new Ra(),
|
|
83923
|
+
pi.registerCallback(uI.ContextCreationStart, (i) => {
|
|
83924
|
+
BI && console.log("Register rapier physics backend"), i.context.physics.engine = new Ra(), i.context.physics.engine.initialize(i.context);
|
|
83925
83925
|
});
|
|
83926
83926
|
const Wc = class {
|
|
83927
83927
|
constructor() {
|
|
@@ -84037,7 +84037,7 @@ const Wc = class {
|
|
|
84037
84037
|
return this.context = A, this._initializePromise || (this._initializePromise = this.internalInitialization()), this._initializePromise;
|
|
84038
84038
|
}
|
|
84039
84039
|
async internalInitialization() {
|
|
84040
|
-
return "env" in import.meta && {}.VITE_NEEDLE_USE_RAPIER === "false"
|
|
84040
|
+
return "env" in import.meta && {}.VITE_NEEDLE_USE_RAPIER === "false" ? !1 : this._hasCreatedWorld ? (console.error("Invalid call to create physics world: world is already created"), !0) : (this._hasCreatedWorld = !0, ZC === void 0 && (ZC = await Promise.resolve().then(() => qoA), await ZC.init()), BI && console.log("Physics engine initialized, creating world..."), this.world = new uE(this._gravity), this.enabled = !0, this._isInitialized = !0, BI && console.log("Physics world created"), !0);
|
|
84041
84041
|
}
|
|
84042
84042
|
/** Check is the physics engine has been initialized and the call can be made */
|
|
84043
84043
|
validate() {
|