Roof.rb v1
-
Thanks, have a good weekend too...
-
It is not working for me. I select the face and get the first dialog box, click ok and nothing happens. No roofs, no second dialog box for layers etc...
This is all I am getting:
I click ok and all I get is what you see minus the dialog box.
Hmmmm.
I tried it with all of them; Gable, Mansard... -
i have the same problem
-
BTW, I am on a PC running XP 5.1
-
tjis is pretty cool, I have not been on long enough to matter lately and when I sign on this afternoon there si a new roof ruby waiting to be tested. I'll try her out. thanks TIG.
-
Thanks for the feedback so far - even if some of it's reporting problems...
Can those of you getting problems please report back with PC/Mac ver, SUp version etc and exact nature of problem - e.g. "after dialog nothing gets made and there are no error dialogs either"... [it would help when you get the problems if you have the Ruby Console Window open and copy me in on any errors that pop up there too]... so I can see if there's a common problem...
Works fine for me (and several others) with PC XP SP2 and Vista SUp 60515.
-
TIG, I tried it out at home and I get the same results as above.
Both computers=
PC
XP service pack 2
SU 6.0.515 -
PC XP Service Pack 2
SU 6.0.515Will not work, nothing happens.
I create a rectangle and push/pull.
Highlite top surface/plugins/roof
Choose whichever version, mansard,gable etc, but nothing happens after this when I would expect the roof to be created.I will give it a go shortly on my Vista Laptop, see if it works with that system.
-
@unknownuser said:
TIG, I tried it out at home and I get the same results as above.
Both computers=
PC
XP service pack 2
SU 6.0.515Same spec' as I have tested it on and it's perfect ! Very confusing...
Videos cards [long-shot] ?Any Ruby Console Error Messages when it is failing ?
-
-
@marne said:
works perfect for me. thank you, great script.
i use xp sp 2 and SU 6.0.515 and it works, it must be anything else...
Thanks for some positive feedback.
Perhaps it's a script clash - this might show in the Console messages ?
The script is packed but its classes include:
class Geom::Vector3d >>> to_flat_angle
class Geom::Point3d >>> is_on_face?
class Sketchup::Face >>> offset_eaves(dist)
and then...
Roof itself has a class 'Roof' with methods:
Roof::hip()
Roof::mansard()
Roof::gable()
Roof::pyramid()
Roof::get_slope()
Roof::help()- plus for data manipulation...
Roof::ordered_edge_points(face)
Anyone know of clashing class/methods in other scripts etc ?
- plus for data manipulation...
-
Eric, you had trouble with the .mht file showing images.
Does you Internet Options > Advanced window look like this ?
It should. -
I am happy to report, initial test produced a roof, a gable roof over a rectangle. I toggled all the menu settings, included the carat, used degrees rather than rise/run, inches rather than ft in,
made a rectangle 30 degree pitch gableattempt to make another gable, I get the attached jpg.
Then I work with the hip settings:
this is the ruby console error when making hip w/ ^45 pitch
BulkChange: 1
1
BulkChange: 2
2
Error: #<NoMethodError: undefined methodto_f' for ["^45"]:Array> (eval):163:in
dialog_hip'
(eval):189:inhip' (eval):2720 (eval):2720:in
call'using 45 w/out the carat doesnt change anything
The most prevelant message is th jpg, it isnt allowing any repeat roofs
Nvidia GE Force 7300 LE
XP SP2
SU vers 6.0.515anything else I can test, let me know
-
I am getting better with it!
I am getting repeat roofs in the smae file. When it quits I close itt down and start another and do it till it gets the jpg. posted earlier
if I enter for pitch; ^45, it seems to me I would get a 12:12 pitch, but I get 12.4 degrees
enter ^68 I get a roof at 20.9 degrees.In the help guide It says enter decimals or on the menu enter inches and when inches are entered on the menu, it shows as feet. example enter 24", it shows as 2'
-
rhankc
I think you are misunderstanding how to enter the roof 'slopes'. It is done differently for hip/mansard and gable/pyramid roofs.
For a hip or mansard/sprocket roof you can only enter the roof slope as an angle in degrees [a number] e.g. 22.5, OR the slope as a ratio [separated by ':'] e.g. 2:5. For these types you CAN'T enter a ridge/apex height using a ^. If you do it should return an error thinking you've entered zero degrees
For a gable or pyramid roof you can enter the angle or ratio as above OR additionally you can specify the ridge/apex height above the fascia in current units by prefixing it with a ^, e.g. ^1234 (here assuming mm this puts the ridge/apex at 1234mm high). Don't use a units suffix or try '/" - so 1234.5 (in mm) is OK as is 18 (in inches) or 1.5 (in feet) but NOT 1'6".
When you make a hip or mansard you need to have one horizontal face selected otherwise you'll get error messages.
When you make a gable you need to select one face that's both horizontal and forms a rectangle, AND also select an edge that's near where you want the 1st gable to be (that's needed to tell the tool which of the rectangle's sides are to form gables and which of them is the 1st one, since you can apply different settings to the 1st and 2nd gables).
When you make a pyramid you need to select one face that's both horizontal and forms a rectangle, AND also select an edge that's on a side where you want the angle for the slope to be taken from - with a non-square pyramid the two pairs of opposing faces have different slopes so you need to do this to indicate which gets the degrees/ratio you've given. Note that you need to select one of this rectangle's edges even if you intend later to use ^1234 as the height of the apex instead of entering degrees or a ratio, as at the point where you set off the tool has no way of knowing what options you might choose later...
Your item about it saying inches in the menu prompts and it showing it in feet is a function of SketchUp: if you are working in Architectural units - inches - and you enter 18" it's taken OK but when you reopen the dialog it will show 1' 6" - the prompt simply tells you that your current units are set to inches [or feet or cm or whatever] - SketchUp displays Architectural inches as feet+inches if it's >12".
-
@tig said:
Does you Internet Options > Advanced window look like this ?
It should.Here is mine at home, I won't be able to check work until Monday.
-
Thanks for the detailed explanation.
I get pyramid roof no problem. I havent tried a mansard, but I will.The only way I can get gable to respond is using a ^ before a specified height. The other techniques dont produce anything. I was seeing the difference in what was entered for eaves etc. and thought it was a SU thing so I had changed my units to decimal-inches and was still getting the ft-in after entering a value in inches. That is why I mentioned it. it is now entering as expected.
After a few roof sessions, (keep making different roof modules) I get the image I posted earlier even though I have the edge and horizontal surface selected. It wont get over the message until I start a new file.
This is going to be a great tool. thanks
-
@rhankc said:
The only way I can get gable to respond is using a ^ before a specified height. The other techniques dont produce anything...
After a few roof sessions, (keep making different roof modules) I get the image I posted earlier even though I have the edge and horizontal surface selected. It wont get over the message until I start a new file.IF you open a new model, open the Ruby Console and then make a rectangle + push'pulled to a volume, then run Roof...Gable and accept all of the defaults that appear in the dialog what happens ?
With your 'non-rectangle' error... it's as if multiple editing make what is a rectangle slightly skewed. Maybe I need to build in some 'tolerance' as to what makes a 'rectangle'...
-
that is the perfect question...
the first run after the initial boot, I built a rectangular cube, and ran the roof tool on gable after selecting one edge and the top plane. I saw nothing happen.I did it again exactly as you described for a gable: nothing happened.
To get a roof model the first attempt, this is what I tried: I went thru the menu and toggled each setting, basically rekeyed everything there and entered 12:12 for a pitch. I got nothing; then I noticed the ^ wasn't included in the pitch indicator, so I set ^12 , and got a low pitch roof.
here is the ruby console script:
Added: 1 :: #Sketchup::Face:0x4e3ad38
Cleared: #Sketchup::Selection:0x4e58480
Added: 1 :: #Sketchup::Face:0x4e3a0c0
Cleared: #Sketchup::Selection:0x4e58480
Added: 1 :: #Sketchup::Face:0x4e3a0c0
Cleared: #Sketchup::Selection:0x4e58480
BulkChange: 1
1
BulkChange: 2
2
Error: #<NoMethodError: undefined methodto_f' for ["1", "2"]:Array> (eval):1385:in
dialog_gable'
(eval):1494:ingable' (eval):2722 (eval):2722:in
call' -
hi halli
Advertisement