build-dxf 0.1.7 → 0.1.8

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/build.js +4 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "build-dxf",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "线段构建双线墙壁的dxf版本",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
package/src/build.js CHANGED
@@ -8016,10 +8016,12 @@ class Scenario {
8016
8016
  }
8017
8017
  // 绘制图形
8018
8018
  async drawGraphics(lines, z, trajectoryJson) {
8019
+ const doorLines = lines.filter((line) => line.userData.isDoor);
8020
+ lines = buildDoubleWallGroup(lines.filter((line) => !line.userData.isDoor), doorLines);
8021
+ lines.push(...doorLines);
8019
8022
  await this.modelLoader();
8020
8023
  await this.windowModelLoader();
8021
8024
  this.height = z;
8022
- console.log("this.height", this.height);
8023
8025
  this.lines = lines;
8024
8026
  if (this.group) {
8025
8027
  this.scene.remove(this.group);
@@ -8108,7 +8110,7 @@ class Scenario {
8108
8110
  });
8109
8111
  let d = [];
8110
8112
  for (const i2 in c) {
8111
- d.push(new THREE.Vector3(c[i2].dian.x, c[i2].dian.y, 3));
8113
+ d.push(new THREE.Vector3(c[i2].dian.x, c[i2].dian.y, c[i2].dian.z));
8112
8114
  }
8113
8115
  const seen = /* @__PURE__ */ new Set();
8114
8116
  const E = d.filter((coord) => {
@@ -8429,7 +8431,6 @@ class Scenario {
8429
8431
  let size = new THREE.Vector3();
8430
8432
  box32.getSize(size);
8431
8433
  cabinetModel.rotation.x = Math.PI / 2;
8432
- console.log("卡农看:", cabinetModel.geometry);
8433
8434
  cabinetModel.scale.set(0.7 / size.x, 0.7 / size.y, 0.3 / size.z);
8434
8435
  this.group.add(cabinetModel);
8435
8436
  }