|
|
@ -296,6 +296,9 @@ export default class Rack3dObject extends THREE.Object3D { |
|
|
const heights = [] |
|
|
const heights = [] |
|
|
for (let i = 0; i < item.dt.bays.length; i++) { |
|
|
for (let i = 0; i < item.dt.bays.length; i++) { |
|
|
const bay = item.dt.bays[i] |
|
|
const bay = item.dt.bays[i] |
|
|
|
|
|
if (bay.topHeight == null || bay.topHeight < 0) { |
|
|
|
|
|
bay.topHeight = 0.5 |
|
|
|
|
|
} |
|
|
const bayHeight = bay.levelHeight[bay.levelHeight.length - 1] + bay.topHeight |
|
|
const bayHeight = bay.levelHeight[bay.levelHeight.length - 1] + bay.topHeight |
|
|
heights.push(bayHeight) |
|
|
heights.push(bayHeight) |
|
|
} |
|
|
} |
|
|
@ -358,8 +361,8 @@ export default class Rack3dObject extends THREE.Object3D { |
|
|
for (let i = 0; i < item.dt.bays.length; i++) { |
|
|
for (let i = 0; i < item.dt.bays.length; i++) { |
|
|
const bay = item.dt.bays[i] |
|
|
const bay = item.dt.bays[i] |
|
|
for (let j = 0; j < bay.levelHeight.length; j++) { |
|
|
for (let j = 0; j < bay.levelHeight.length; j++) { |
|
|
const levelHeight = bay.levelHeight[j] |
|
|
const levelHeight = bay.levelHeight[j] - 0.05 // 0.05为横梁自身高度的一半
|
|
|
if (levelHeight <= 0.005) { |
|
|
if (levelHeight <= 0.0) { |
|
|
continue |
|
|
continue |
|
|
} |
|
|
} |
|
|
hBarMatrix.push({ |
|
|
hBarMatrix.push({ |
|
|
|