v3 #95
@@ -44,7 +44,7 @@ export default function PolygonGenerator({
|
|||||||
});
|
});
|
||||||
|
|
||||||
const polygons = turf.polygonize(turf.featureCollection(validLineFeatures));
|
const polygons = turf.polygonize(turf.featureCollection(validLineFeatures));
|
||||||
|
|
||||||
renderWallGeometry(wallPoints);
|
renderWallGeometry(wallPoints);
|
||||||
|
|
||||||
if (polygons.features.length > 0) {
|
if (polygons.features.length > 0) {
|
||||||
@@ -115,6 +115,7 @@ export default function PolygonGenerator({
|
|||||||
const quaternion = new THREE.Quaternion();
|
const quaternion = new THREE.Quaternion();
|
||||||
quaternion.setFromUnitVectors(new THREE.Vector3(1, 0, 0), direction);
|
quaternion.setFromUnitVectors(new THREE.Vector3(1, 0, 0), direction);
|
||||||
wallMesh.quaternion.copy(quaternion);
|
wallMesh.quaternion.copy(quaternion);
|
||||||
|
wallMesh.name = "agv-collider";
|
||||||
|
|
||||||
groupRef.current?.add(wallMesh);
|
groupRef.current?.add(wallMesh);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user