diff --git a/src/components/ThreeViewer/Scene.jsx b/src/components/ThreeViewer/Scene.jsx index 91f0f9b..60061cf 100644 --- a/src/components/ThreeViewer/Scene.jsx +++ b/src/components/ThreeViewer/Scene.jsx @@ -19,8 +19,6 @@ const Scene = ({ geometries, simulationMeshes, setSimulationMeshes, - pvSystems, - setPVSystems, selectedMesh, setSelectedMesh, selectedPVSystem, @@ -32,6 +30,8 @@ const Scene = ({ }) => { // showTerrain decides if the underlying Map is visible or not const [showTerrain, setShowTerrain] = useState(true) + // A list of visible PV Systems - they get visible after they are drawn on a building and calculated + const [pvSystems, setPVSystems] = useState([]) window.setPVPoints = setPVPoints const position = [ diff --git a/src/pages/Simulation.jsx b/src/pages/Simulation.jsx index 1b1465b..7059b8e 100644 --- a/src/pages/Simulation.jsx +++ b/src/pages/Simulation.jsx @@ -15,8 +15,7 @@ function Index() { // simulationProgress is used for the loading bar const [simulationProgress, setSimulationProgress] = useState(0) - // A list of visible PV Systems - they get visible after they are drawn on a building and calculated - const [pvSystems, setPVSystems] = useState([]) + // pvPoints are the red points that appear when drawing PV systems const [pvPoints, setPVPoints] = useState([]) @@ -68,8 +67,6 @@ function Index() { geometries={geometries} simulationMeshes={simulationMeshes} setSimulationMeshes={setSimulationMeshes} - pvSystems={pvSystems} - setPVSystems={setPVSystems} selectedMesh={selectedMesh} setSelectedMesh={setSelectedMesh} selectedPVSystem={selectedPVSystem}