From ffd39ddf6fc9b0280af4f2f5810212cf23072c6c Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@63.com>
Date: 星期六, 25 十二月 2021 11:05:31 +0800
Subject: [PATCH] #
---
static/js/data/ConveyData.js | 1 -
static/js/object/StoreConvey.js | 15 ++++++++++++---
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/static/js/data/ConveyData.js b/static/js/data/ConveyData.js
index b6002a1..6c089ef 100644
--- a/static/js/data/ConveyData.js
+++ b/static/js/data/ConveyData.js
@@ -10,7 +10,6 @@
},
rotateY: 0,
traverse: {
- color: 0xAAAAAA,
scale: {
x: 1,
y: 1,
diff --git a/static/js/object/StoreConvey.js b/static/js/object/StoreConvey.js
index 908cd44..2eed2d4 100644
--- a/static/js/object/StoreConvey.js
+++ b/static/js/object/StoreConvey.js
@@ -41,6 +41,11 @@
child.material = new THREE.MeshLambertMaterial({
color: 0xAAAAAA
});
+ if (child.name === "Box034" || child.name === "Box035") {
+ child.material = new THREE.MeshLambertMaterial({
+ color: 0x000000
+ });
+ }
}
});
chainList.map(item => {
@@ -84,10 +89,14 @@
let traverse = info.traverse;
clone.traverse (function (child) {
if (child instanceof THREE.Mesh) {
+ // 鎷変几
child.scale.set(traverse.scale.x, traverse.scale.y, traverse.scale.z);
- child.material = new THREE.MeshLambertMaterial({
- color: traverse.color
- });
+ // 棰滆壊
+ if (traverse.color !== undefined) {
+ child.material = new THREE.MeshLambertMaterial({
+ color: traverse.color
+ });
+ }
}
});
}
--
Gitblit v1.9.1