Jump to content

KingChaos

Member
  • Posts

    262
  • Joined

  • Last visited

Posts posted by KingChaos

  1.  

    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.

    image.thumb.png.af7b151596480b253639dca6c481fd2c.png

     

    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.image.png.fe984559de45b9aeb12119252abf4ada.png

     

     

    BR KC

  2. Hey,

     

    maybe i am too stupid but nothin happened ^^ except crashing VW a few times.

     

    image.thumb.png.1f5f269758f17b94e4bf7bbf576c38b7.png

    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

  3. 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.

  4. of course i knew this "crashing all the sketch segments" from TopSolid.

     

    But there u can repair all the stuff because u simply have to manipulate the points and direction, where the dimensioning is.

     

    It was really headache in the start, but did u once get how it works its working for u 🙂

  5. Hi,

     

    totally naive i made a red symbol out of a Cabinet 3D from the extragroup.

     

    Now i try to put in database entries for width/length and Height into my symbol.

     

     

    Can someone please give me some hints, how to go further?

     

    in the "Data-Manager" i find something, but only 

     

     

    The Symbol definition does not contain my red saved symbol i made out of the 3D-cabinet.

    image.thumb.png.84bfd550424b170409a2096979e34561.png

     

    in plug in of third parties i find something "Korpus", but not my red symbol

    image.thumb.png.a1c2d2dca37933bdb98c8c4c1c647891.png

     

    what is the plan i have to follow?

     

    image.png.48c26c3effe042065ab34152f307e16c.png

    are the nodes i find to use some database stuff.

     

     

    BR KingChaos

     

     

  6. Hi,

     

    I have to move some objects in an angle but i only got vectors, so i dont know how to calculate a vector out of an angle and there is only "vector to angle" node.

     

     

    MAybe someone has a reverse node or knows how this goes better with different nodes.

     

    I have a list of path extruded rectangles along lines, which generated out of a polyline (red).

     

    image.png.f8176d1480d32119e5b2d7b2a2a57871.png

     

    But the profile which is extruded allways is "placed" in the middle (center of bounding box) of my path extrude.

     

    But I need this extrudes BEHIND or INFRONT the line (The Profil has to be extruded in the edge of my ).

     

    image.thumb.png.3ec369a15e5c3df8c67d0df9f6cc091d.png

    So i thought i can read out a list of angles of the lines and use the "MOVE" node to move the Boxes half height and half width.

     

    But the node needs a vector not an angle.

     

    BR KC

    Extrusionsbauteil_Version_2.vwx

  7. 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?

  8. Hi there,

     

     

    which Node i need to split a poly into a list of lines?

     

    I am trying to make a path extrude along a polyline, but not as 1 object along the hole polyline.

     

    Each segment should be a path to extrude a geometry along it without connection to 1 object along the poly.

     

     

    br KC

  9. Hi Pat,

     

     

    thx.

     

    Thats clear, but it was confusing, that such constraining is not working between objects.

     

    There is results a modification of one thing overrides the existing constraint?

     

     

    If I try to constrain different rectangles, it is modifying those "other constraints".

     

    Is there any "horizontal" or "orthogonal" contraint i can place manually?

     

     

    But what is happening in the 2. clip? The measures are tipping, after i made it 0 and then with some input >100.

     

     

    br THX kc

     

  10. hi there,

     

     

    can someone tell me, whats wrong with those ass. dimensioning?

     

    I am trying to find the logic behind it.

     

    How can i place some constraints (parallel, othogonal, incidence ..), so that VW wont destroy my sketch/associative dimension?

     

    When do u suggest to use this associative dimensioning, what for it was made, does someone use it?

     

    f.E.

    I made a polygon and used the object dimensioning to learn something about it.

     

    Sometimes (the left and upper part of my polygon) it works on all 3 anchor points, while i input diff values into the dimension, the right and bottom one only works on one of the anchor points without destroying themselves.

     

     

    BR KC

  11. does someone knows, what of the code the wrapped marionette i have to copy into my script editor?

     

    image.png.02d731c605985dc99e66f777ab99c189.png

     

    import Marionette 
    import math 
    import operator 
    Marionette.execution_mode = Marionette.ExecutionType.Export 
    ###################### IfInStringABS_Wrap_79 ######################### 
    class IfInStringABS_Wrap_79: 
        Handle = vs.Mrntte_GetNodeHandle(79)
        @Marionette.NodeDefinition 
        class Params(metaclass = Marionette.OrderedClass): 
            this = Marionette.Node("Wrapper") 
            this.SetDescription("""Wrapper""") 
            this.SetLinksObjects()
            InputKante_60_Lifted = Marionette.OIPControl( 'InputKante', Marionette.WidgetType.Int, 134)
            InputKante_60_Lifted.SetDescription("An OIP control that accepts integer values")
            KantenNr_61_Lifted = Marionette.OIPControl( 'KantenNr', Marionette.WidgetType.Int, 2)
            KantenNr_61_Lifted.SetDescription("An OIP control that accepts integer values")
            ABS_Output = Marionette.PortOut()
            ABS_Output.SetDescription("The result item")
        
        
        def RunNode(self): 
            ###################### String_62 ######################### 
            class String_62: 
                Handle = vs.Mrntte_GetNodeHandle(62)
                #COMMAND;READONLYREFFILE;[VWLibDef]/Input\String.py;
                #Modified April 2017
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'String' )
                    this.SetDescription('A text string defined in the OIP')     
                    
                    #Input Ports
                    
                    #OIP Controls
                    String = Marionette.OIPControl( 'string', Marionette.WidgetType.Text, '')
                    String.SetDescription('A text string')
                    
                    #Output Ports
                    s = Marionette.PortOut()
                    s.SetDescription('The string')
                
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    s = self.Params.String.value
                    
                    #script
                    
                    #outputs
                    self.Params.s.value = s
        
            ###################### String_89 ######################### 
            class String_89: 
                Handle = vs.Mrntte_GetNodeHandle(89)
                #COMMAND;READONLYREFFILE;[VWLibDef]/Input\String.py;
                #Modified April 2017
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'String' )
                    this.SetDescription('A text string defined in the OIP')     
                    
                    #Input Ports
                    
                    #OIP Controls
                    String = Marionette.OIPControl( 'string', Marionette.WidgetType.Text, '')
                    String.SetDescription('A text string')
                    
                    #Output Ports
                    s = Marionette.PortOut()
                    s.SetDescription('The string')
                
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    s = self.Params.String.value
                    
                    #script
                    
                    #outputs
                    self.Params.s.value = s
        
            ###################### InputKante_60 ######################### 
            class InputKante_60: 
                Handle = vs.Mrntte_GetNodeHandle(60)
                #COMMAND;READONLYREFFILE;[VWLibDef]/Input\Int.py;
                #Modified April 2017
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'Int' )    
                    this.SetDescription('An integer value') 
                    
                    #Input Ports
                    
                    #OIP Controls
                    Int = Marionette.OIPControl( 'Integer', Marionette.WidgetType.Int, 0)
                    Int.SetDescription('An OIP control that accepts integer values') 
                    
                    #Output Ports
                    i = Marionette.PortOut()
                    i.SetDescription('The value')
                    
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    i = self.Params.Int.value
                    
                    #script
                    
                    #outputs
                    self.Params.i.value = i
        
            ###################### KantenNr_61 ######################### 
            class KantenNr_61: 
                Handle = vs.Mrntte_GetNodeHandle(61)
                #COMMAND;READONLYREFFILE;[VWLibDef]/Input\Int.py;
                #Modified April 2017
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'Int' )    
                    this.SetDescription('An integer value') 
                    
                    #Input Ports
                    
                    #OIP Controls
                    Int = Marionette.OIPControl( 'Integer', Marionette.WidgetType.Int, 0)
                    Int.SetDescription('An OIP control that accepts integer values') 
                    
                    #Output Ports
                    i = Marionette.PortOut()
                    i.SetDescription('The value')
                    
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    i = self.Params.Int.value
                    
                    #script
                    
                    #outputs
                    self.Params.i.value = i
        
            ###################### If_In_String_70 ######################### 
            class If_In_String_70: 
                Handle = vs.Mrntte_GetNodeHandle(70)
                #COMMAND;READONLYREFFILE;[VWLibDef]/String\If In String.py;
                #added to library 02/28/2018 MFarrell
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'If In String' )
                    this.SetDescription( 'If a sub string exists in the given full string, this node returns True, if not, it returns False.' )
                    
                    #Input Ports
                    sFull = Marionette.PortIn( '' )
                    sFull.SetDescription( 'The full string to search' )
                    sSub = Marionette.PortIn( '' )
                    sSub.SetDescription( 'The sub string' )
                    
                    #OIP Controls
                    
                    #Output Ports
                    b = Marionette.PortOut()
                    b.SetDescription( 'True or False, depending on whether the sub string is in the full string' )
            
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    full = self.Params.sFull.value
                    sub = self.Params.sSub.value
                    
                    #script
                    bool = []
                    if str(sub) in str(full):
                        bool.append(True)
                    else:
                        bool.append(False)
                        
                    #outputs
                    self.Params.b.value = bool
        
            ###################### ABS_Output_83 ######################### 
            class ABS_Output_83: 
                Handle = vs.Mrntte_GetNodeHandle(83)
                #COMMAND;READONLYREFFILE;[VWLibDef]/Data Flow\If.py;
                #Modified by MFarrell May 2017
                @Marionette.NodeDefinition
                class Params(metaclass = Marionette.OrderedClass):
                #APPEARANCE
                    #Name
                    this = Marionette.Node( 'If' )
                    this.SetDescription( 'If test is true, pass the value from true otherwise pass the value from false' )    
            
                    #Input Ports
                    true = Marionette.PortIn( None, 'itemTrue' )
                    true.SetDescription( "An item" )
                    false = Marionette.PortIn( None, 'itemFalse' )
                    false.SetDescription( "An item" )
                    test = Marionette.PortIn( True, 'bTest' )
                    test.SetDescription( "A boolean value" )
            
                    #OIP Controls
            
                    #Output Ports
                    out = Marionette.PortOut('item')   
                    out.SetDescription( "The result item" )
            
                #BEHAVIOR
                    
                def RunNode(self):
                    #inputs
                    test = self.Params.test.value
                    true = self.Params.true.value
                    false = self.Params.false.value
            
                    #script
                    if test:
                        out = true
                    else:
                        out = false
            
                    #outputs
                    self.Params.out.value = out
        
            if Marionette.execution_mode != Marionette.ExecutionType.PIOExecute: 
                vs.BeginGroup()
            String_62.Params.String.value = """ABS""" 
            String_62.Params.s.SetConnected( True )
            if String_62.Params.this.initFunc:
                String_62.Params.this.initFunc(String_62)
            String_62.RunNode(String_62) 
            ABS_Output_83.Params.true.value = Marionette.OutputMerge( ABS_Output_83.Params.true.value, String_62.Params.s )
            ABS_Output_83.Params.true.blocked = ABS_Output_83.Params.true.blocked or String_62.Params.s.blocked
            if String_62.Params.this.finalFunc:
                String_62.Params.this.finalFunc(String_62)
            Marionette.NotifyForOutValue( String_62, 0, String_62.Params.s ) 
        #########################################################################
            String_89.Params.String.value = """ """ 
            String_89.Params.s.SetConnected( True )
            if String_89.Params.this.initFunc:
                String_89.Params.this.initFunc(String_89)
            String_89.RunNode(String_89) 
            ABS_Output_83.Params.false.value = Marionette.OutputMerge( ABS_Output_83.Params.false.value, String_89.Params.s )
            ABS_Output_83.Params.false.blocked = ABS_Output_83.Params.false.blocked or String_89.Params.s.blocked
            if String_89.Params.this.finalFunc:
                String_89.Params.this.finalFunc(String_89)
            Marionette.NotifyForOutValue( String_89, 0, String_89.Params.s ) 
        #########################################################################
            InputKante_60.Params.i.SetConnected( True )
            if InputKante_60.Params.this.initFunc:
                InputKante_60.Params.this.initFunc(InputKante_60)
            InputKante_60.Params.Int.value = self.Params.InputKante_60_Lifted.value 
            InputKante_60.RunNode(InputKante_60) 
            If_In_String_70.Params.sFull.value = Marionette.OutputMerge( If_In_String_70.Params.sFull.value, InputKante_60.Params.i )
            If_In_String_70.Params.sFull.blocked = If_In_String_70.Params.sFull.blocked or InputKante_60.Params.i.blocked
            if InputKante_60.Params.this.finalFunc:
                InputKante_60.Params.this.finalFunc(InputKante_60)
            Marionette.NotifyForOutValue( InputKante_60, 0, InputKante_60.Params.i ) 
        #########################################################################
            KantenNr_61.Params.i.SetConnected( True )
            if KantenNr_61.Params.this.initFunc:
                KantenNr_61.Params.this.initFunc(KantenNr_61)
            KantenNr_61.Params.Int.value = self.Params.KantenNr_61_Lifted.value 
            KantenNr_61.RunNode(KantenNr_61) 
            If_In_String_70.Params.sSub.value = Marionette.OutputMerge( If_In_String_70.Params.sSub.value, KantenNr_61.Params.i )
            If_In_String_70.Params.sSub.blocked = If_In_String_70.Params.sSub.blocked or KantenNr_61.Params.i.blocked
            if KantenNr_61.Params.this.finalFunc:
                KantenNr_61.Params.this.finalFunc(KantenNr_61)
            Marionette.NotifyForOutValue( KantenNr_61, 0, KantenNr_61.Params.i ) 
        #########################################################################
            if not If_In_String_70.Params.sFull.blocked and not If_In_String_70.Params.sSub.blocked:
                If_In_String_70.Params.sFull.SetConnected( True )
                If_In_String_70.Params.sSub.SetConnected( True )
                If_In_String_70.Params.b.SetConnected( True )
                if If_In_String_70.Params.this.initFunc:
                    If_In_String_70.Params.this.initFunc(If_In_String_70)
                maxPCnt = 0
                maxPCnt = If_In_String_70.Params.sFull.MaxLen( maxPCnt ) 
                maxPCnt = If_In_String_70.Params.sSub.MaxLen( maxPCnt ) 
                if If_In_String_70.Params.this.nodeListAbsorb or maxPCnt == 0: 
                    try:
                        If_In_String_70.RunNode(If_In_String_70) 
                    except:
                        Marionette.ReportException()
                    ABS_Output_83.Params.test.value = Marionette.OutputMerge( ABS_Output_83.Params.test.value, If_In_String_70.Params.b )
                    ABS_Output_83.Params.test.blocked = ABS_Output_83.Params.test.blocked or If_In_String_70.Params.b.blocked
                else: 
                    p0List = If_In_String_70.Params.sFull.ExtendList( maxPCnt ) 
                    p1List = If_In_String_70.Params.sSub.ExtendList( maxPCnt ) 
                    out0 = None
                    out0blocked = False
                    for p0, p1 in zip(p0List, p1List): 
                        If_In_String_70.Params.sFull.value = p0 
                        If_In_String_70.Params.sSub.value = p1 
                        try:
                            If_In_String_70.RunNode(If_In_String_70) 
                        except:
                            Marionette.ReportException()
                        out0 = Marionette.OutputMerge( out0, If_In_String_70.Params.b ) 
                        out0blocked = out0blocked or If_In_String_70.Params.b.blocked
                    If_In_String_70.Params.b.SetValue( out0 )
                    If_In_String_70.Params.b.blocked = out0blocked
                    ABS_Output_83.Params.test.value = Marionette.OutputMerge( ABS_Output_83.Params.test.value, If_In_String_70.Params.b )
                    ABS_Output_83.Params.test.blocked = ABS_Output_83.Params.test.blocked or If_In_String_70.Params.b.blocked
                if If_In_String_70.Params.this.finalFunc:
                    If_In_String_70.Params.this.finalFunc(If_In_String_70)
            else:
                If_In_String_70.Params.b.blocked = True
                ABS_Output_83.Params.test.value = Marionette.OutputMerge( ABS_Output_83.Params.test.value, If_In_String_70.Params.b )
                ABS_Output_83.Params.test.blocked = True
            Marionette.NotifyForOutValue( If_In_String_70, 0, If_In_String_70.Params.b ) 
        #########################################################################
            if not ABS_Output_83.Params.true.blocked and not ABS_Output_83.Params.false.blocked and not ABS_Output_83.Params.test.blocked:
                ABS_Output_83.Params.true.SetConnected( True )
                ABS_Output_83.Params.false.SetConnected( True )
                ABS_Output_83.Params.test.SetConnected( True )
                if ABS_Output_83.Params.this.initFunc:
                    ABS_Output_83.Params.this.initFunc(ABS_Output_83)
                maxPCnt = 0
                maxPCnt = ABS_Output_83.Params.true.MaxLen( maxPCnt ) 
                maxPCnt = ABS_Output_83.Params.false.MaxLen( maxPCnt ) 
                maxPCnt = ABS_Output_83.Params.test.MaxLen( maxPCnt ) 
                if ABS_Output_83.Params.this.nodeListAbsorb or maxPCnt == 0: 
                    try:
                        ABS_Output_83.RunNode(ABS_Output_83) 
                    except:
                        Marionette.ReportException()
                else: 
                    p0List = ABS_Output_83.Params.true.ExtendList( maxPCnt ) 
                    p1List = ABS_Output_83.Params.false.ExtendList( maxPCnt ) 
                    p2List = ABS_Output_83.Params.test.ExtendList( maxPCnt ) 
                    out0 = None
                    out0blocked = False
                    for p0, p1, p2 in zip(p0List, p1List, p2List): 
                        ABS_Output_83.Params.true.value = p0 
                        ABS_Output_83.Params.false.value = p1 
                        ABS_Output_83.Params.test.value = p2 
                        try:
                            ABS_Output_83.RunNode(ABS_Output_83) 
                        except:
                            Marionette.ReportException()
                        out0 = Marionette.OutputMerge( out0, ABS_Output_83.Params.out ) 
                        out0blocked = out0blocked or ABS_Output_83.Params.out.blocked
                    ABS_Output_83.Params.out.SetValue( out0 )
                    ABS_Output_83.Params.out.blocked = out0blocked
                if ABS_Output_83.Params.this.finalFunc:
                    ABS_Output_83.Params.this.finalFunc(ABS_Output_83)
            else:
                ABS_Output_83.Params.out.blocked = True
            Marionette.NotifyForOutValue( ABS_Output_83, 0, ABS_Output_83.Params.out ) 
        #########################################################################
            self.Params.ABS_Output.SetValue( ABS_Output_83.Params.out.value )
            self.Params.ABS_Output.blocked = ABS_Output_83.Params.out.blocked
            if Marionette.execution_mode != Marionette.ExecutionType.PIOExecute: 
                vs.EndGroup() 
        

    try: 
    ################################################# 
        IfInStringABS_Wrap_79.Params.InputKante_60_Lifted.value = 134 
        IfInStringABS_Wrap_79.Params.KantenNr_61_Lifted.value = 2 
        if Marionette.execution_mode != Marionette.ExecutionType.PIOExecute and IfInStringABS_Wrap_79.Params.this.nodeLinksObjects: 
            vs.BeginGroup()
        if IfInStringABS_Wrap_79.Params.this.initFunc:
            IfInStringABS_Wrap_79.Params.this.initFunc(IfInStringABS_Wrap_79)
        IfInStringABS_Wrap_79.RunNode(IfInStringABS_Wrap_79) 
        if IfInStringABS_Wrap_79.Params.this.finalFunc:
            IfInStringABS_Wrap_79.Params.this.finalFunc(IfInStringABS_Wrap_79)
        if Marionette.execution_mode != Marionette.ExecutionType.PIOExecute and IfInStringABS_Wrap_79.Params.this.nodeLinksObjects: 
            vs.EndGroup()
            if Marionette.execution_mode != Marionette.ExecutionType.Export:
                vs.Marionette_LinkObject(IfInStringABS_Wrap_79.Handle, vs.LNewObj())
        Marionette.NotifyForOutValue( IfInStringABS_Wrap_79, 0, IfInStringABS_Wrap_79.Params.ABS_Output ) 
    #########################################################################
    except Marionette.MarionetteError: 
        pass 
     

  12. Hi,

     

    i am trying to convert a number from 1-4 digits into a predefined text.

     

    Input is this "1 to 4" digit-number, which can be a and an single-digit (1,2,3 or 4) which has to be compared whether the single digit is contained in the 4 digit.

     

    The script has to return a string "ABS" if the input is:

     

    1234  & 1 -> ABS  1 is included

    234 & 1 -> "" 1 is not included

    312 & 1 -> ABS

     

    i dont know which node i have to use. I searched for some who splits the 4 digit into 4 single digits, but i cant find it.

     

    This Script i have to use in a bom-Chart for interiorcad. 

     

     

    I would rather use the excel functions, but this function does not work in the vw chart i think or i am not able to find the syntax i have to use.

    If someone can tell me, how the syntax of this function is, i dont need the marionette.

     

    e4ea7067-86ce-4f86-9682-1b95bf772729.png

     

    BR KC

     

×
×
  • Create New...