@adatechnology/game-floorplan-three 0.3.0 → 0.3.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/dist/index.global.js +3 -2
- package/dist/index.global.js.map +1 -1
- package/package.json +10 -10
package/dist/index.global.js
CHANGED
|
@@ -14705,13 +14705,14 @@ uniform mat4 uNodes[${nodes.length}]; attribute float aNodeIndex; attribute vec3
|
|
|
14705
14705
|
const crackLen = clamp2(0.03 + ratio * 0.2, 0.03, 0.8);
|
|
14706
14706
|
let exitPoint;
|
|
14707
14707
|
if (penetrated) {
|
|
14708
|
-
|
|
14708
|
+
const exitDist = p.spec.contains || p.spec.fill !== void 0 && p.spec.fill < 0.5 || p.thickness < pathLen * 0.5 ? pathLen : Math.min(pathLen, effM + layersThickness(p.layers, face) / slant + layersThickness(p.layers, -face) / slant);
|
|
14709
|
+
exitPoint = vec.madd(entry2, d, exitDist);
|
|
14709
14710
|
const hole = addHole(o, p, entry2, n, caliber / 1e3 * (mat.ductility >= 0.3 ? 1 : 1.5), true, exitPoint, src);
|
|
14710
14711
|
if (p.layers.length > 0) spallOuter(o, p, exitPoint, -face, vec.scale(n, -1), Math.max(0.03, caliber / 1e3 * 4), src);
|
|
14711
14712
|
addBreach(o, p, entry2, Math.PI * (hole.diameter / 2) * (hole.diameter / 2), E, d, src);
|
|
14712
14713
|
if (mat.ductility >= 0.5 && p.thickness <= THIN_SHEET_DISHING) addDent(o, p, entry2, n, Math.max(caliber * 3 / 1e3, 0.012), clamp2(E * 2e-5, 1e-3, 0.03), src);
|
|
14713
14714
|
if (brittle && mat.fracture === "shatter") addCrack(o, p, entry2, n, crackLen, src);
|
|
14714
|
-
if (p.spec.contains && (p.st.liters ?? 0) >
|
|
14715
|
+
if (p.spec.contains && (p.st.liters ?? 0) > 1e-4) {
|
|
14715
14716
|
emit({
|
|
14716
14717
|
...base(o, src),
|
|
14717
14718
|
type: "leak",
|