Hi guys
I have made a script that moves each of these 1256 boxes (Buildings) down until they hit the terrain mesh. The model itself seems perfectly fine and not particularly processor heavy at all.
As soon as i run the script, everything starts crashing and it says its trying to move almost 1.5 million extrusions. I cant seem to figure out what i have managed to do here
I have attached the script below with the geometry and the move component un attached. As soon as you try to move the geometry is when it all falls apart!
Site Topography Project Buildings Code.gh (1.6 MB)
Any help would be awesome please guys
You have 2 problems
Graft the geometry there
And suppress the null item of the 2 projected directions
1 Like
Hi @jake_courtenay ,
You have a null item in your Project Point Output giving you 2 points when you should only have 1.
So when you feed this into your Vec2PT it’s not an even data tree alignment, furthermore, in feeding your original geometry into the move component it will move each building 1200+ times because your input isn’t grafted.
Graft the input, ensuring that you have 1 T input for every 1 G input and you should be ready to rock and roll!
Graph Space:
Model Space:
20240218_Site Topography Project Buildings Code_Response_01a.gh (1.6 MB)
Hope that helps, cheers!
1 Like
Thankyou very much for the solution and explanation! I’m still pretty new to working with data trees and all this. Its almost quite helpful running into these issues really, as it gives me a better idea of how grasshopper works with all the data.
Cheers again for the help
1 Like
For sure! Always good to work through actual use cases you want to implement and learn how to add additional functionality as you go. Happy to help, cheers!
1 Like