Room centre location

One of the difficulties of documenting in Revit is the inability to place rooms precisely in the centre of the room. Ideally, Revit would automatically snap to the centroid when in the process of placing a room, instead of just aligning to adjacent elements. Since the reference crosshairs of the room are turned off by default, initially the position of the room may seem irrelevant. However, when attempting to ‘tag all not tagged’, Revit will place tags centred to the room’s location. This constraint means that drawings can appear messy and illegible. To solve this problem, Parametric Monkey has developed two custom Dynamo nodes, both of which are available via the Parametric Monkey Dynamo package.

The ‘Room.CentreLocation‘ node moves all rooms within the project to the centroid of the room. If you have an odd-shaped room, and the centroid is going to fall outside of the room boundary, the node will keep the room in its current position. Under the hood, the script collects all rooms within the project and their associated boundary. The centroid of the boundary is then calculated, and a containment test performed to test whether the new location (centroid) is contained within the room. If true, the rooms are moved to their new position with the rest remaining as-is.

Once all the room have been repositioned, it is possible to move any existing room tags to the new room location point. While it is possible to use the ‘tag all not tagged’ command within Revit, you may have some rooms that either don’t need tags or which require a different tag family. By using Dynamo and referencing the tags already placed in the project, users have greater control over the outcome.

The ‘RoomTag.MoveToRoomLocation‘ node is based on the script by Modelical. However, the benefit of using the Parametric Monkey Dynamo package over Modelical’s is that the Parametric Monkey node will automatically select all the room tags in the project. The problem with having to select which tags to update manually is as follows. Firstly, using the ‘Select model elements’ node in Dynamo, you need to draw a window to reference Revit elements. It is not possible to have a pre-selection or use Ctrl to select multiple elements. The alternative, therefore, is to isolate the room tags for easy selection. However, it is not possible to isolate the room tag category solely. For room tags to be visible, rooms must also be visible. Therefore, having the script collect the room tags automatically is preferable. Note that the script will search for any tags that contain the term ‘Room Tag’ in the family name. If you name your families something different, you’ll need to modify the node as necessary.


Repositioned rooms and room tags

13 Comments on “Room centre location

  1. Any way this could be adapted to instead of shifting the room to its centroid, it could be leverage to report the placed center of room to obtain the length x width of its extents to that placed center location?

    • Hi Rob. Do you mean it reporting the rooms overall dimensions like 6x4m? This can be done by using a bounding box of the room. Or do you mean the width relative to the (uncentred) room location? This is possible too but how do you determine the width from the length? What scenario are you thinking of applying this to?

      • I’m thinking the way a slab direction tag works. This would allow you to grab length x width based on an uncentered non rectangular space easier.

        • I can look into it. Would it be better for the node to reference a detailed component, such as a setting out point, rather than the room?

  2. I am having the old issue of this package upon installation using the Dynamo Package Manager the manager wants me to uninstall the archilab package. I tried to uninstall, install BVN package, and then tried to resinstall archilab package and it wants me to uninstall BVN. I saw on a forum to download the BVN package manually and then place the files in the correct directories however I cannot find a link anywhere to the latest BVN package files. BVN does not come up in a search on this sites package search engine. Where can I find the latest BVN files to download? Thank you.

    • Hi. Yes this is a problem with how the Package Manager works. What you need to do if installing via the package manager is to search for BVN and install. It will say that some packages need to be uninstalled first (namely Lunchbox and Archi-lab from memory). They will be marked for removal. You need to close Dynamo and Revit to fully uninstall them. Then you must reopen Revit and Dynamo and try to install BVN again. This will automatically install the dependency packages including Archi-lab. You don’t need to manually install this. Yes it is a pain.

      To install them manually as you described. However, the BVN package has been depreciated as we are in the process of transferring ownership to another user account (as I am no longer at BVN) – again this is way harder than what it should be! So it can still be downloaded via the Package manager but not sure about the website. I’ll be launching a new package soon in the next few days which should address this issue.

      • Hi, I got this to work finally in Dynamo 2.0 and Revit 2017. The Room.CentreLocation Node contains the Lunchbox Room Element Collector Node. Within the Lunchbox Room Element Collector Node, there is a Python Script. I edited line 81 inside the Python Script.

        1. Insert the Room.CentreLocation node into a new Dynamo script.
        2. Edit the Room.CentreLocation node.
        3. Inside the Room.CentreLocation.dyf script, edit the Lunchbox Room Element Collector node.
        4. Edit the Python Script inside Lunchbox Room Element Collector.dyf.
        5. Go to line 81, crv = seg.Curve and change it to crv = seg.GetCurve()

        Update and save the two nodes and that should fix it!

        Or, to make it easier, I’ve deconstructed both nodes and created the Dynamo script that is ready to run. You can download at my dropbox at


        • Hi Emmy

          Thant you so must for making it easy for people like me (just getting started with dynamo)
          I have a question (hope it is okay) when I rum the script I get the following error from “List.SortSublists”
          “Error: Custom node difinition is not loaded!”
          Do you know what I need to load to get it working?

          Best wishes

          • Sine. That node is from the BVN package. Are you using the Parametric Monkey package and nodes?

  3. @Paul have you released your new package yet? Also is it possible to make the rooms selection based? I know it was said in the thread about the difficulties in selecting room tags selectively but can it be done with rooms?

  4. Hi Jaysyn. Yes the Parametric Monkey package has been launched. However the node hasn’t been updated to be selection based. If you wanted to do this you would just need to replace ‘Room.GetAll’ with either ‘Springs.SelectElement’ or ‘Springs.Collector.CurrentSelection’.

  5. Greetings from London. Sorry to bother you but I was wondering if you could help me with a little issue. I am trying to learn Dynamo and I have followed some instructions of your paper Everyday Dynamo. I have installed the BVN package, but when I try to insert certain nodes from it, the nodes do not have the TOGGLE input to them, although on the figures (on your paper), they do. Example: The node Room.CentreLocation, on your figure, it is shown with a TOGGLE input, but when I import it in my Dynamo file, it does not. (hence I cannot connect the Boolean node to it). Any help would be greatly appreciated.

    • Hi Antony. You should use the Parametric Monkey dynamo package instead, as per previous comments.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.