PLAYING WITH DYNAMO PLAYER

August 18th, 2017 Posted by computation, Download, Dynamo, production, Revit, Tools 2 comments on “PLAYING WITH DYNAMO PLAYER”

Dynamo Player has recently (As of Revit 2018.1 Release) received some rather funky additions, namely the ability to have Inputs and Outputs.

While still, content wise, a little behind the seriously awesome Data-Shapes package (Shoutout Mostafa El Ayoubi), it gives beginners and those not particularly keen to delve into Visual Programming the ability to use tools generated by others which is a big win.

This blog post will release 5x free scripts that have been built with Dynamo Player in mind.  It will showcase a few different approaches to the use of Player, some as simply a big button, others with inputs and outputs and will also explore how you can have defaults that will save over multiple use – to effectively customise the scripts to your firms style.

Dynamo 1.3.1 was used for the generation of all available Scripts and Images. Revit 2018.1 will be required to access the Dynamo Player inputs and outputs. Most of these scripts will work with the player and default settings regardless.

Colour Non Room-bounding Elements

designtech_ColourNonRoomBoundingElements_v1.0 will allow you to simply colour (So using a non-invasive approach) any element within your open view. It colours by Elements that have the ‘Room Bounding’ box unticked and applies a Red colour override and Black line pattern.

The script is set-up to have a series of inputs that, while containing default values, allow you to input your own choice of Line Pattern, Line Weight, and Fill Pattern. It uses a name filter, so you will have to apply correct title casing to your inputs for it to correctly function: If you have incorrectly typed in a viable name for the above options it will simply default back to the original.

After running the script, there are two output nodes that showcase the Successful Overrides and Failed Overrides

 

The default options are depicted below:

After running with the default options, your chosen view (In this case a 3D one of the Basic Revit House) will colour override all elements that are non room-bounding.

If we wish to change the graphical outputs, we simply go in and, using the correct title casing, type in other options such as Triangles or Steel.

This graph will work in any type of view: Be it 3D, plan, section, elevation and so-on. The only view type this doesn’t work with are those which cannot have a colour override applied – such as Camera views

Delete Views Not on Sheets

designtech_DeleteViewsNotOnSheets_v1.0 will allow you to delete any View that isn’t currently placed on a Sheet. It will take into account dependent views and all view types (Section, plan etc).

The script doesn’t contain any inputs, but will give two output counts: Deleted Views and Retained Views. If you do not wish to know the outputs you can click the run button in Player without expanding the inputs menu and it will simply run.

 

The pre-run state is depicted below:

The output from a simple run is just Run Completed. It has gone through each of the views in the project and deleted out every element that isn’t currently on a Sheet.

However, for the curious, there are outputs that show the counts of Deleted Views and Retained Views

Renumber Doors by Rooms

designtech_RenumberDoorsByRooms_v1.0 will automatically Renumber all Doors (Note: Won’t pick Curtain Doors) based off the To Room parameter. If there is no room which the Door is opening into it will then, and only then, pick the From Room parameter instead.

For the Door Number itself, the script will do a count based off the Doors in each room and append an alphabetic suffix running sequentially upwards. The numbering sequence will run on an X/Y grid using the X-Axis as dominant. We append a Prefix as chosen by the user and the output format is in as follows: Prefix-Room Number-Suffix. 

The script contains two inputs, a phase (So you can choose to ignore existing doors) and a prefix, both of which are set before running.

 

The pre-run state is depicted below:

In the input options, we simply choose a Phase and an Prefix prior to running.

After the run, all our Doors have been Renumbered based off the above criteria.

Map Parameters: Simple

designtech_SimpleMapParameters_v1.0 will automatically map data between two Parameters in Revit.

It allows you to choose a Category of Element (Such as Doors), a parameter to Map From and a parameter to Map To. Please note that it will only allow you to map data between relevant parameter fields (i.e you cannot map to Read-Only parameters or text into a number and so on). We have a single output that showcases the mapped Elements.

The example used below is simply mapping the Doors mark value to the comments. This might be useful when you need to retain the old naming system before implementing a new one.

 

The pre-run state is depicted below:

After choosing our inputs and hitting run, it will map across the data between the two chosen parameters in a single Element.

Delete Unwanted CAD Content

designtech_DeleteUnwantedCADContent_v1.0 will automatically delete out any Imported CAD link (But will leave all linked Links), any Imported Line Patterns and any Imported Line Styles.

You have a simple true/false toggle at the start to choose whether or not you want to delete out the Imported CAD geometry. It will by default delete all the Graphic Styles and Line Pattern Elements.

Outputs showcase Deleted Element count values for each of the three categories.

The pre-run state is depicted below:

After running the script, the Line Patterns, Line Styles and any Imported CAD Geometry will be deleted out of the file. The outputs showcase count values of what has been cleaned up.

Tags: , , ,

2 comments on “PLAYING WITH DYNAMO PLAYER”

Carl Storms says:

Great Post, love seeing what can be done with Dynamo Player

EMR says:

thank you very much,
awesome tools.

Leave a Reply

Your email address will not be published.This is a required field!

<small>You may use these <abbr title="HyperText Markup Language">HTML</abbr> tags and attributes:<br> <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>