Onink Posted October 25, 2021 Share Posted October 25, 2021 Is there a way to create a parametre list that works for multiple marionette objects? I want to have a couple of marionette objects for which I can use the same input by selecting a=20 and b=40 for example. And that multiple marionette objects respond to that. 1 Quote Link to comment
Pat Stanford Posted October 25, 2021 Share Posted October 25, 2021 I think we need a better description of what you really want to do to be able to offer a reasonable solution. Can you give us a real world example including the WHY you want to do this rather than I just want to change objects A and B? Quote Link to comment
KingChaos Posted October 27, 2021 Share Posted October 27, 2021 sounds like he wants to drive a lot of marionettes having the same input variables with one parameter in the file were he wants to place them. Quote Link to comment
SimA Posted October 28, 2021 Share Posted October 28, 2021 I am currently writing the data to a database. The objects get the input from this database and change accordingly after the update. ...Google translater.... 1 Quote Link to comment
KingChaos Posted October 28, 2021 Share Posted October 28, 2021 but how to drive any value into given marionettes with input variables? Ok i know how to place a symbol, but how u put in the variables into all by marionette placed symbols? I can imagine, that some kind of "get input variables" into a list and then put the global variables of your main marionette into the placed symbols? Quote Link to comment
DomC Posted October 28, 2021 Share Posted October 28, 2021 (edited) As I understand, you want something like global variables for the PIOs on the Document. Like Title Block Project Data. There are several possibilities. I think it depends on what you can handle yourself. 3 Examples of Strategies: 1. You could get the values from a Record handle (the record definition itself not from an Object > It takes the default value). So you had a central control over those values. 2. You could push the values (with a Dialog) directly to the Marionette PIOs 3. Take the value from a worksheet This depends how your Marionette-Code is designed. I guess SimA - Method (Method 1?) would be the best option. To the second Methode. Maybe this is the hardest one because changing the OIP of Marionette is not as simple like with Standard PIOs. There is an Example in the Gallery to make this or you could code A dialog-Window Enter the Value and Push them on your Objects. For myself I use that method to backup values from the marionette on a record. So the script is updated I am able to pull the values if necessary from that record. Code something like this: import json #Globals recName = 'MarionetteObject3D' #recName = 'MarionetteObject2D'# Check, the Marionette Rec-Name for your Marionette PIOs fldName = 'NodeDef_OIPControls' #collect Objects objs = [] def getObj(h): objs.append(h) criteria = "(NOTINDLVP & NOTINREFDLVP & (C='MarionetteObjects'))" vs.ForEachObject(getObj, criteria) OIP_Name = 'Mauerlicht' #Name of the Parameter OIP_value = 1200 #value of the Parameter for obj in objs: sOld = vs.GetRField(obj, recName, fldName) #vs.AlrtDialog(str(sOld)) j = json.loads(sOld) for OIP_field in j['data']: name = OIP_field['varName'] if OIP_Name in name: value = OIP_field['value'] OIP_field['value'] = OIP_value vs.SetRField(obj, recName, fldName, json.dumps(j)) vs.ResetObject(obj) Edited October 28, 2021 by DomC 1 Quote Link to comment
Gregi Posted October 28, 2021 Share Posted October 28, 2021 (edited) I guess you could create any master-object which is connectet to a database an name it. in your marionette you get this object by name an gets its database entrys. If your master-object is a symbol with symbol-text you have a "Master-Table" or something like that. Edited October 28, 2021 by Gregi Quote Link to comment
Onink Posted October 28, 2021 Author Share Posted October 28, 2021 On 10/27/2021 at 2:47 PM, KingChaos said: sounds like he wants to drive a lot of marionettes having the same input variables with one parameter in the file were he wants to place them. This is exactly what I want. I've used Top Solid Wood before (a different drawing programme) they use a parameter list to control al these parameters. This way it's easy to adjust the objects. You have a base object which can be adjusted in a couple directions by changing the parameters. What DomC suggests is probably going to work. I'm not that good at scripting, but I'll give it a try. Thanks already! 1 Quote Link to comment
KingChaos Posted October 29, 2021 Share Posted October 29, 2021 Dont use the T.. ..... Word 🙂 or i am going to cry. Quote Link to comment
KingChaos Posted October 29, 2021 Share Posted October 29, 2021 hi Gregi, the Master is the symbol, which contains all the other symbols and has an OIP where u can manipulate the height and Depth of the cabinets. The Length is driven by the segmentlength of the polyline (controlgeometry). u can PM me, if u have some time to have a look. Quote Link to comment
KingChaos Posted October 29, 2021 Share Posted October 29, 2021 sprich ruhig deutsch 🙂 oder PM ok? Quote Link to comment
KingChaos Posted October 29, 2021 Share Posted October 29, 2021 Hey, maybe i am too stupid but nothin happened ^^ except crashing VW a few times. The debug tells me "True" so VW was succesful to placing my value into the database of the 3D-Cabinet, but the Cabinet is still in original dimension. It named the symbol in the group exactly what i wanted, but something is not right, i dont get what it is. 😞 Symbol mit Parameters einfuegen_V2.vwx Quote Link to comment
DomC Posted October 29, 2021 Share Posted October 29, 2021 (edited) Hi The Field name of "Gesamt Breite" ist 'Width' not "Breite". If you change that, you will get the right object. If you set a name of the object, you change the name on the object info on the very buttom. Not the Cabinet Name. The Cabinet Name ist generated by a higher "act of nature" we are not able to write that Name field with a Script. Also ungroup I would not use. Because your Symbol is inserted as a PIO. The group around every marionette-created geometry you cant eliminate with the ungroup node. I think this could be changed with the node itself "linkedGeometry" This here, created the group: Edited October 29, 2021 by DomC Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 Thanks Dom, i have to check. Ah now it works thanks. Additional question, "is it possible, to have some variables not beeing "named" by condition or otherwise deleted out of hte oip?" f.E. If my POlyline has 4 segments, i would like to have the inputvariables height and Width of the 5. and 6. Object are not beeing shown in the oip. BR KC Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 @DomC Hi and thx a lot so far. its developing. is there any Dropdown possibility for choosing the different symbols like the "get texture" nude? I would place my symbols in a specific folder (Interior) in the ressource manager and like to have a pulldown with all symbols existing there. The Rest is working fine, except: - textformatting the measuretext (i have no chance for center aligne my text) -> should be red and "right aligned" - textformatting the assemblyname-text (RB_01 .... RB_06) should be green and left aligned - making an object node out of it VW crashed BR and thx for your help. Maybe u have some solutions for there problems. KC Namensinputmit Aktivierung.vwx Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 @DomCnext problem is, if i place the same symbol-cabinet multiple times, vw wont rename it all cabinets having the same name f.E. "Korpusmöbel-53". That will result, if i ungroup the cabinets, that all the parts 3D have not a single databasenetry. Only the first one placed by marionette has all entries in all databases. the others are not connected to any db. so if i will later on use those parts i HAVE to manipulate the name, or make VW renaming them. 😞 damn, it was such a good plan. Quote Link to comment
SimA Posted November 1, 2021 Share Posted November 1, 2021 @KingChaos Ich kann den Knoten auch nicht in ein Objekt umwandeln --> Absturz. Ist es möglich, dass die Kontrollgeometrie Schwierigkeiten macht? Habe vor Kurzem eine Kontur in eine Gruppe verfrachtet und anschliessend den Gruppennamen für die Erzeugung des Objekts verwendet. So kannst du übrigens auch mehrere Geometrie gleichzeitig (in der Gruppe) verarbeiten. Gruss 1 Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 Das ist nur eine polylinie, bei dem andern bauteil geht es genau so Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 Also die POlylinie in eine Gruppe tun und die Gruppe mit Namen versehen geht nicht. Quote Link to comment
Onink Posted November 2, 2021 Author Share Posted November 2, 2021 So you want to name every extrusion in a marionette object and even when you have the same object more than once. I tried that too, but didn't have time to really work it out. Have you seen my post 'naming solids in marionette' ? This might help.. 1 Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 I dont have any extrusion in this file, i only place red symbols made out of XG Cabinets and got problems with the predefined names of these cabinets because the name is not able to be manipulated with set record field. Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 please link your post, i cant find it. Quote Link to comment
Onink Posted November 2, 2021 Author Share Posted November 2, 2021 Here's the link: 1 Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 hmm, what is the reason for that cabinettool? Do you have the interiorcad? i got no useful application for not interiorcad objects cabinets because we have to cnc them. therefore all stuff i place has to be an interiorcad part 3D or cabinet 3D with 3D-parts. Maybe i misunderstood your english post but i am struggling with naming such cabinets out of the XG generator. This objects are not nameable by marionette, DomC told me. If that is true it is a "death blow" for this solution. 😞 Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.