the UUID will be different if you delete them, plus you will break the GH script if you delete the inputs.
That’s why working with layer. If you don‘t need the ID for the script. Oops, may bake and than clear all elements which weren‘t backed in last step. Very interesting. I will have a look at this as soon as I can.
Still had no time for that.
But data dam could be a solution. It will store the initial object after deleting it, so the script don’t break. Than bake and update data dam before deleting again.
What is that?
like a button you can click on. if click on it, the input will be updated. Mostly used for large definitions, so you can change something in the beginning, without instant calculating the part after the data dam. when clicking on it, the output will be updated, so the rest of the scripts also changes.It’s like a storage, which gets updated when you click on it.
Isn’t that what Elefront, Human and others do??
Just used Human to transfer data between two scripts. Never used it in the same script for updating. So maybe possible. But to be true, I don’t know why I would do that. I mean, if want to loop something I will use Anemone and not always bake, load, delete again. But whatever.
Here’s something which is working, but not bulletproof. Geometry Pipeline to load objects from layer. Now you can modify them. Now you click 3 buttons. 1. Update data dam; 2. Delete objects; 3. Bake objects again.
update geo.gh (9.3 KB)
May it’s helping…
I have to mention I cannot figure out how to work with this “pipeline”. Instead, I directly added a surface to the “input” brep.
After clicking on the first button, the surface is deleted. Second button does nothing (I assume this is supposed to pass the rotated surface to the last script, but it throws an error (see below)
Pipeline links all geometry’s on a specific Layer. You can choose layer by name. So you break it, if you remove pipeline.
Make sure the layer name for baking = layername for pipeline.
I ordered and named the buttons you have to press from 1-3. you can ignore error.
Ok, I think I got the hang of it.
Unfortunately, if I bake Pipeline catches both the original and the baked one. I assume this is what your script was supposed to delete.
That Pipeline though, really cool thing, didn’t even know it existed, thanks a lot Tim
I kind of wanna stick with the OOTB components.
I remember reading somewhere a different method to access user attributes (besides Elefront)
Thanks Rickson, but I really don’t want to use Elefront.
If you don‘t like elefront, try human as @Rickson mentioned.
One is understood though, GUID will always be different after every bake.
It’s not that I don’t like it, obviously it has its apllications, but I wanna stick to OOTB components as much as possible, so I can learn how to do it, and not rely on stuff I have no control of. If it’s an open source tool - ok, but if it’s closed, I don’t know how it works and if I need something slightly different I cannot change it.
Not to meniton that Human UI (if this is what you mean by “human”) is a complete mess I don’t know where to begin.
Edit the bake c# so it bakes the objects with the initial id‘s.
I assume you know how to script c#, vb. or whatever. Because I don‘t know any standard component to edit attributes if you don‘t want to use plugins.
No, I mean human.
I don’t know that one, I’ll check.
Not in depth but I’ll figure it out. I am trying currently to copy properties from one object to another using python.
I don‘t know if you need the exact id for something, but if not, you can import Initial attributes like name, color, layer etc and bake the edited geometry with these attributes. So the id changes, but Name etc will be the same.
If you are working your way through this in python (a gh python component), this might help. I’m not sure this counts as OOTB…but, here you go. This example is gathering object usertext, that was assigned to objects in rhino.
import scriptcontext as sc import Rhino values =  sc.doc = Rhino.RhinoDoc.ActiveDoc objs = sc.doc.Objects.Find(x) a = objs.Attributes.GetUserStrings() for v in a: values.append(objs.Attributes.GetUserStrings().GetValues(v)) b = values c = objs.Attributes.Name print dir(objs) sc.doc = ghdoc
The dir function in python is really helpful when digging down into objects.
This is using Rhino 6. It also is not as robust as C# compiled solutions, (like Human or Elefront). But, it’s the general idea.
objAtts_ghpython.gh (6.6 KB)
Yes, using scripting components is considered OOTB.
I was struggling translating one csharp script I found in the forums and now I understand why. It was because of the x data type.