Antonio Landsberger
Distributor-
Posts
294 -
Joined
-
Last visited
Reputation
153 SpectacularPersonal Information
-
Occupation
ComputerWorks employee
-
Location
Germany
Recent Profile Visitors
6,804 profile views
-
Marionette Resources for Beginners
Antonio Landsberger replied to Robert Anderson's topic in Marionette
Hi @Stefan V The answer to your question will come down to the specific situation. If you have a list of values, you'll want to use the "Flatten" node first. Then it depends on whether you want to convert a string to a number (no decimals) or if you want to convert a string to a float (number with decimals). For float conversion you can use the "Float" node. For number conversion you can use the "Function" node and write "int(x)" in the info palette. Then there is the issue, that your floats use commas instead of dots as a delimiter. So, you'd have to change the comma for a dot after flattening, then use the Float node, but only if the value is a string. You see, this is a bit more complicated. -
@Giobbe Check out this page explaining all the possible OIP options for Marionette Nodes and how to implement them: https://github.com/Vectorworks/developer-scripting/blob/main/Marionette/pages/Implement a Node.md
- 8 replies
-
- 2
-
-
- marionette tool
- button
-
(and 1 more)
Tagged with:
-
Vectorscript equivalent to "ObjectData"?
Antonio Landsberger replied to trevorgooch's topic in Vectorscript
Do you know, if there is already an entry for this specific wish in JIRA? I couldn't find one. If there is, please let me know. -
Unfortunately doing it this way is pretty bad performance wise, rather than initially filtering by the active layer within the Objs by Crit node. That's why an OIP checkbox for "currently layer only" would be nice as an improvement of this node.
-
Where could be the issue? Since it's a single node I post both the document and the code here: Write symbol names in worksheet.vwx @Marionette.NodeDefinition class Params(metaclass = Marionette.OrderedClass): #APPEARANCE #Name this = Marionette.Node( 'List all symbol names in worksheet' ) this.SetDescription( 'Running this node will first create a worksheet, then fill it will the names of all symbols in the resource manager.' ) def RunNode(self): import os HSFPath = vs.GetFPathName() FileName = os.path.basename(HSFPath) WorksheetName = FileName[0:-4] #script resourceListID, numItems = vs.BuildResourceList( 16, 0, '' ) WorksheetHandle = vs.GetObject(WorksheetName) if WorksheetHandle == None: vs.CreateWS(WorksheetName, numItems, 1) #{Save the current AutoRecalc state} autoRecalcState = vs.GetWSAutoRecalcState(WorksheetName) #{Turn off worksheet Auto Recalculation} vs.SetWSAutoRecalcState(WorksheetName, False) for cnt in range( numItems + 1 ): vs.SetWSCellFormulaN(WorksheetHandle, cnt, 1, cnt, 1, vs.GetNameFromResourceList( resourceListID, cnt )) vs.SetWSAutoRecalcState(WorksheetName, autoRecalcState) vs.RecalculateWS(WorksheetName)
-
-
For layer visibility there are HideLayer ShowLayer GrayLayer
-
Record Formats and Marionette Objects
Antonio Landsberger replied to Marc Powell's topic in Marionette
Exporting Marionette networks (particularly big ones) as Python results in a convoluted mess of variables. I don't believe, that kind of code is suitable for creating plug-in objects. -
be able to choose the splash screen ?
Antonio Landsberger replied to Gaëtan R.'s topic in General Discussion
Does anyone know, what exactly this image is depicting? -
Here's the new link: https://github.com/Vectorworks/developer-scripting/blob/main/Function Reference/Functions/vstGetEventInfo.md in case someone stumbles upon this entry like I did.
-
Updating Object Nodes Based on Title Block Data
Antonio Landsberger replied to nbakovic's topic in Marionette
Hi @nbakovic What you want is either an event triggered script run, which Marionette and scripts have no access to or knowledge of, or a script that runs in certain intervals to check for changes. The latter is also not possible, because that would essentially be a script running in the background, but Vectorworks is always blocked during script runtime, thus there could also be no change to check while the script is running. You could create a menu command (from a Marionette wrapper), that shows you the relevant information you want to see - no matter where in the document you are. It could even be information from different objects and records (all in this one message).
