Jump to content


Vectorworks, Inc Employee
  • Posts

  • Joined

  • Last visited

Posts posted by sbarrett

  1. In all of the nodes in the default library, there are prefixes for the inputs and outputs that tell you the type of data coming in or out of the node. 

    s = string

    n = number

    i = integer (whole number)

    h = a Vectorworks object, such as a piece of geometry

    b = True or False

    p = point

    v = vector

    item = multiple value types

    list = list of items


    These aren't all but they are the most common. When in doubt, match output prefixes to input prefixes when connecting nodes.

  2. Wrapping is just a way to package a script. You can wrap a script by right-clicking on a node and selecting the appropriate command. When you wrap a script, the Input nodes that have been given names will appear in the OIP when the wrapper is selected. Once a network is wrapped, you can then convert that wrapper to a menu command or Marionette object.

  3. There aren't any specific tutorials, all I can recommend is to take apart the script you have already and try to figure out how they work. There are some layer nodes that you can use too. You can find out the layer of the space and filter it with Marionette. I have attached a sample network to the other one I sent you that does this. The network is not finished as I don't know exactly how you want the filtering to work, but I tried to show you how to implement it.


    VW Rooms only_NvdS_Marionette2.vwx

  4. Hello @C.Miguel- sorry for the late response but I think I have discovered a bug in the story setup commands. I have attached a file that works, but it is important that you set up storys BEFORE you create classes. This is one of the few things that have a set order of operations in Vectorworks. I would also recommend you add in the command CreateStoryLayerTemplate and use that to create your layers, not creating them first and then associating them to a story. 


    The bug I noticed is something to do with units. The document units of the attached file are millimeters, and the command seems to work as millimeters, but if it is set to different document units, it still reads the number as millimeters. I will file a bug but until then I would recommend creating your scripts to set up files using millimeters and then change the document units after running the script.


    Create Storys mm.vwx

    • Like 1
  5. Hello @Mi&D


    I have made a script that I think does what you are asking. It takes the total area from the worksheet and writes it to the Additional Info 2 field of the correct space. It works on all the spaces in the document. I have wrapped the network and given it the name "Apply Apartment Area to Spaces." It works, but the space tags do not update automatically - they have to be "bumped." What worked for me was to select all of the spaces, and choose the correct space label from the dropdown list (even if it is already selected). This will update the tag to show the correct info.

    VW Rooms only_NvdS_Marionette.vwx

  6. I am not sure if it is possible to tie objects to viewport scale or annotation space, but there is a command that reads layer scale and you can use that to scale your tags if they are being placed in the design layer. I created a node that gets the layer scale that an object is in - if the scale is 1:1, the node will return "1" and if the scale is 1:50, the node will return "50." This was based on the Get Layer node, I just added a command to get the layer scale instead.





    • Like 1
  7. There is a way you can create this. You can use a Popup node in the Input folder. You have to edit the script inside by deleting the top line of the script and then adding the choices into the appropriate part of the script. The output of this node is the index value of the selection you make from the popup list. for example, if you have four choices: ['Red', 'Orange', 'Yellow', 'Green'] the corresponding index values will be [0, 1, 2, 3]. You can build a corresponding list of values and use a Get Item node to draw the correct value from the list. 



  8. When a Marionette node creates geometry it is always placed in a group. The group is named based on the name of the node that created it as well as a random number - this ensures that when you run the script again, the object will be deleted and recreated, because that named group will be replaced. To edit any geometry created by marionette nodes, you will have to ungroup it first, no matter whether you use the group or ungroup nodes.

  9. The only way to do this is to create a menu command. To create this kind of network, you will need an Object by Criteria node as the node that connects the object to the network. In the text field in that node you type "SEL=TRUE" and then convert the network to a menu command. The menu command will exist in Tools > Marionette Commands > [New Command]. To use it, select an object and then run the menu command.


    However, this may not be exactly the type of network that you are looking for.


    If you want to create a Marionette object with control geometry you can use a Control Geometry node instead, and then convert the network to a Marionette object.


    If you just want a network that references existing geometry (not as an MO or MC) then you must use a Name node. You have to give the geometry a name in the OIP, and then put that name in the text field of the Name node.


  10. I believe this will always happen because of the nature of Marionette objects. In this way they are also similar to hybrid symbols - the 2D geometry get treated differently than the 3D geometry. If it becomes problematic for the script, you can use the Set PRefID To Ground node in the Object Info folder to set the object to the layer plane while your script is acting on it. However I do not know if the object will stay on the layer plane if you ungroup the Marionette network from the control geometry.

  11. It can be difficult to use multiple control geometries - the best way I have found is to group them all together and make the group your control geometry. Then you can use a Contents node to access them. Once you have the list of control geometries from the Contents node, you can filter them by name or type, etc.

  12. Hello DE,


    Whenever you convert control geometry and a network to a Marionette object, the geometry will most likely move. What is happening is the geometry is centered over the wrapper, and that becomes the insertion point/center of the Marionette object. You can think of a Marionette object as a symbol or plug-in object - it lives as a resource to be placed in the drawing - it doesn't remember its original location. Having multiple pieces of control geometry can also be tricky. Are the separate pieces of control geometry keeping the correct spatial relationship between each other?


  • Create New...