michaelk Posted July 16, 2016 Share Posted July 16, 2016 I'm posting a couple of scripts that I've found useful when dealing with cabinets and countertops. I've been using them in a more hacky way for a while and just recently, (Thanks Patrick, Marissa, Hippocode, and Raymond!) made them more presentable. Still pretty ham-fisted coding, but it works! If there is any interest in them I may make a prettier version with dialog boxes. But first let's see if there is any interest. It started with a wish list for a graphic way to insert cabinets. These scripts will insert cabinets between two clicks. Just run one of the scripts, click a starting point and click an ending point. The script will insert cabinets on the "left" side of the line between the two clicks. Think of it as going counter clockwise around a room. There are different versions: Fast Base Cabinets +18,24,36 will insert base cabinets with a standard width (18, 24, 36 inches) and one more to fill in the remaining distance, if any. It will also create a countertop floor object on top. Fast Base Cabinets 1,2,3,4,5 creates 1,2,3,4, or 5 base cabinets of equal length. Fast Upper Cabinets +18,24,36 does the same thing for upper cabinets. Fast Upper Cabinets 1,2,3,4,5 does the same thing for upper cabinets. Fast Countertop creates just a countertop. I often find it helpful to separate this step. (You can turn off countertops in the Fast Base Cabinet scripts by changing the value for WouldYouLikeACountertopWithThat from TRUE to FALSE.) The parameters are easily editable to your own taste. I think these scripts should work back to 2014. Please let me know if there are any issues. These scripts assume Imperial dimensions in inches. Metric users can change the default values in the declarations after the Procedures SetCabinetParameters and LastSetCabinetParameters. mk Quote Link to comment
rDesign Posted August 22, 2016 Share Posted August 22, 2016 michaelk - thanks for posting these scripts, they look like they'll be pretty handy. Quote Link to comment
alanf Posted November 16, 2016 Share Posted November 16, 2016 On 7/15/2016 at 11:03 PM, michaelk said: I'm posting a couple of scripts that I've found useful when dealing with cabinets and countertops. I've been using them in a more hacky way for a while and just recently, (Thanks Patrick, Marissa, Hippocode, and Raymond!) made them more presentable. Still pretty ham-fisted coding, but it works! If there is any interest in them I may make a prettier version with dialog boxes. But first let's see if there is any interest. It started with a wish list for a graphic way to insert cabinets. These scripts will insert cabinets between two clicks. Just run one of the scripts, click a starting point and click an ending point. The script will insert cabinets on the "left" side of the line between the two clicks. Think of it as going counter clockwise around a room. There are different versions: Fast Base Cabinets +18,24,36 will insert base cabinets with a standard width (18, 24, 36 inches) and one more to fill in the remaining distance, if any. It will also create a countertop floor object on top. Fast Base Cabinets 1,2,3,4,5 creates 1,2,3,4, or 5 base cabinets of equal length. Fast Upper Cabinets +18,24,36 does the same thing for upper cabinets. Fast Upper Cabinets 1,2,3,4,5 does the same thing for upper cabinets. Fast Countertop creates just a countertop. I often find it helpful to separate this step. (You can turn off countertops in the Fast Base Cabinet scripts by changing the value for WouldYouLikeACountertopWithThat from TRUE to FALSE.) The parameters are easily editable to your own taste. I think these scripts should work back to 2014. Please let me know if there are any issues. These scripts assume Imperial dimensions in inches. Metric users can change the default values in the declarations after the Procedures SetCabinetParameters and LastSetCabinetParameters. mk Hi Michael, Where would i find the Cabinet scripts you wrote about? Would LOVE to try them out! Thanks Alan Quote Link to comment
michaelk Posted November 16, 2016 Author Share Posted November 16, 2016 Alan I'll post the 2016 version. Something changed in 2017 so that the cabinets offset one cabinet from the points the user clicked. Not sure why - I haven't had time to get into it. Maybe one of the VS geniuses will help me out with that? @JimWany news as to when uploads to the old forum will be restored to the new forum? Hope this works for you. Double click a script from the palette and then click two points on the drawing. Cabinets will be drawn between those two points on the left side of an imaginary line connecting those points. If you are clicking on top of already drawn walls make sure Wall Insertion Mode is off. Otherwise some of the cabinets will be sucked into the wall. The results are not predictable :-) hth mk Cabinet Scripts~.vwx 1 Quote Link to comment
Vectorworks, Inc Employee PVA - Admin Posted November 16, 2016 Vectorworks, Inc Employee Share Posted November 16, 2016 @michaelkNot so far, but it isn't forgotten, it may take until the second wave of forum upgrades though which I'm a good portion of the way through now. Quote Link to comment
alanf Posted November 16, 2016 Share Posted November 16, 2016 Thanks so much, Michael! Looking forward to trying it out! Quote Link to comment
alanf Posted November 16, 2016 Share Posted November 16, 2016 Michael, You're a damned genius. Awesome script. Thank you. Quote Link to comment
alanf Posted November 16, 2016 Share Posted November 16, 2016 Sorry, follow-up question: How do I bring your script into another file? Thanks so much Quote Link to comment
michaelk Posted November 16, 2016 Author Share Posted November 16, 2016 Glad they work for you. I find them helpful for quick layouts. When I get time I'll make it do corners and fancy stuff. The scripts are in the resource browser. Just import them like any other resource. It might help to also copy and paste a set of cabinets from the sample drawing into your drawing so that the textures and cabinet hardware also follow. mk Quote Link to comment
michaelk Posted December 5, 2016 Author Share Posted December 5, 2016 I don't think anyone (besides me ) is actually using these, but just in case - here is the 2017 update to the cabinet scripts. Now the script works the opposite direction from the 2016 version. In 2017 draw this script clockwise around the room. The cabinets and countertops will appear on the right side of the line. mk Cabinet Scripts Update~ v2017.vwx 1 Quote Link to comment
The Hamma Posted June 27, 2019 Share Posted June 27, 2019 Love the script but I do have a question. Do you know why the countertop does not have the correct texture in VW 2019 Quote Link to comment
michaelk Posted June 27, 2019 Author Share Posted June 27, 2019 NO! And it bugs me, too.! I’m assuming that either something changed in texture on floor objects that I need to account for in the script or there is a bug in floor objects in 2019. 1 Quote Link to comment
The Hamma Posted June 27, 2019 Share Posted June 27, 2019 (edited) Could the "BeginFloor" command be replaced with a simple extrude? If you ungroup the floor, it becomes a floor and a rectangle. At this time the floor can be rendered by setting the correct attributes. Edited June 27, 2019 by The Hamma Quote Link to comment
michaelk Posted June 27, 2019 Author Share Posted June 27, 2019 The problem with an extrude is that it shows up as wireframe in top/plan view. Then you see all the lines between the base cabinets - which is the one of the reasons I don't use the built in countertop. I just looked at the differences between floor since 2018 and 2019. I think it's a bug. The work around is to force a redraw. Changing a render parameter like the mapping or the scale instantly makes it work in 2019. I'll submit a bug report when I get home and, in the mean time, I'll try scripting a forced redraw to see if that fixes it. Thanks for pointing it out. I see it almost everyday and think, "I should figure out why that doesn't work anymore" 🤓 Quote Link to comment
michaelk Posted June 27, 2019 Author Share Posted June 27, 2019 Interesting. In both 2018 and 2019 if you take a floor object and Convert to Group you get 6 3D polygons. In 2018 if you take a floor object and Ungroup you get the original polygon. 1n 2019 if you take a floor object and Ungroup you get the original polygon, a floor object and a group containing the original shape as a polyline. That object is sometimes not selectable. Quote Link to comment
michaelk Posted October 24, 2020 Author Share Posted October 24, 2020 For those of you who are using these scripts, I've made a tool version. And it's pretty funny. Clearly I don't understand everything that happens under the hood when creating cabinets so this tool sometimes creates FrankenCabinets. My workflow is usually to use this tool to play around with layouts and then ungroup it to get real VW cabinet objects. Changing a parameter on the real objects cures their FrankenCabinet appearance. I don't know if I'll keep working on this. It works just barely well enough at the moment. But I'm open to ideas 🙂. You can see a video demonstration here. If there are ever any updates it's more likely to be current there. Cabby.vso Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.