I have one. Free. http://www.smustard.com/script/LayerChange
Todd
I have one. Free. http://www.smustard.com/script/LayerChange
Todd
If you want to change the default displayed unit in a model via Ruby, you have to change an Option (See Ruby Help>Classes>OptionManager). They are all stored in a Hash. If you want more help, lemme know.
Also, you might try typing in "16.meters" (no quotes).
Todd
I've been asked a few times to explain how to add a component to a model from Ruby.
This short example shows the basics of how to do it. There are only a few steps required, but it's not readily intuitive when first getting started with Ruby. So, without further ado... here you go. (See attached script without all the formatting to run it yourself.)
**%(green)[# How to Create a component and add it to you model from Ruby.
new_comp_def = Sketchup.active_model.definitions.add("MyCube") ;
# Now, define some points for an arbitrary face.
%(blue)[points = Array.new ;
points[0] = ORIGIN ;]# "ORIGIN" is a SU provided constantpoints[1 = [100, 0 , 0] ;
points[2] = [100, 100, 0] ;
points[3] = [0 , 100, 0] ;]
%(green)[# Now, add the face to the new component definition.
newface = new_comp_def.entities.add_face(points) ;%(green)[# returns a Face
newface.reverse! if newface.normal.z < 0 ;%(green)[# flip face to up if facing down
newface.pushpull(100) ;%(green)[# extrude it up to make a cube
trans = Geom::Transformation.new ;%(green)[# an empty, default transformation.
Sketchup.active_model.active_entities.add_instance(new_comp_def, trans) ;**
Obvioulsy, this can be expanded upon to be more interesting.
There is another way to add a component to a model, and that is through the model.place_component method. The place_component method allows the user to left-click where the component will be placed. You can define the insertion_point so that the specific insertion point of the component is at the tip of the cursor.
Todd
I didn't look at the script, but I can tell from your picture what you are trying to do.
First, draw the circle for the end of the log. Then draw an interior arc at the bottom of the circle which would represent the portion of the log that you would cut away. Then, remove the lowermost section of the circle to create the final profile you need. Then, pushpull it.
Todd
http://www.sketchucation.com/forums/scf/sas/Ruby/Picture%201.png
I perhaps picked the wrong user name. I got registered, and made a post, but it appears my stats did not carry over.
Todd
p.s. I used my userid as it displays here on this forum, telling me I am logged on.
I have no idea what's going to be in SketchUp V7. My money would be on these features:
Todd
Haven't forgotten about this - just working on a higher priority project.
Todd
The script is written and even uploaded to smustard (but hidden). I need to check the packaging on it to be sure it's ready for prime time. I'll go over it this evening.
Todd
Got one. I need to package it up. Works great. Even mimics the weird sort order.
I'm thinking an xml file would be more interesting/purposeful. Perhaps I'll provide an option for text or xml. Right now it's tab delimited.
Todd
Oh Coen - you are my hero...
(Oh, brother.)
LOL.
Yes, I lke the forums here. Not as tight and compact as the old @Last forum, but that's ok. I like the larger text entry box for sure.
One of the pains with the old forums was actually getting a change made. That certainly is not a problem with this forum. Thank you and the other moderators.
Whereever this forum evolves to is OK by me.
Todd
Get it here: http://www.smustard.com/script/SceneRename
Full tutorial on the site. It can renumber and rename-and-renumber.
Enjoy, Todd
This one is another in the series of CAD cleanup scripts. It's different from Closeopens and is more suited for Architectural CAD imports than CloseOpens.
Available here with Tutorial and examples: http://www.smustard.com/script/ExtendCloseLines
Todd
I wrote a clock that works in SketchUp, and I'm still waiting for my ticket!
And Gai - that clock is correct two times a day!
Todd
Ross, I was on FormFonts the other day and looked at your blueprint styles. Very nice. The classic is great! Good job.
Todd
"View new topics" is there - I just found it. It's on the left side, not the right side.
Lookin' good SCF. I too would like the view new posts.
Todd
No big deal - I understand. Not a problem.
Todd
Todd Burch
@unknownuser said:
Todd, I HAVE a backup of October 1st. The problem is importing the posts into the new forum. Each post is assigned a forum id which does not exist anymore, meaning I do not think it can be done. The only option is to install a board just for the sake of archiving, with all the potential security risks involved since I need to set all the permissions just for that one board again and that will take forever.
This is just one of those things...
Just pulling your chain Coen.
Do you think the IDs can be translated? If the are in a PHP / mySQL database, then perhaps an SQL UPDATE statement is the answer. (I've been working with SQL since 1984 - I've written a few lines of it - just haven't messed with non-mainframe versions of RDBMSs (relation database management systems))
If they are in a flat file, then Ruby can do that (which translates into "I can do it") - I would just need to know what the data looks like. How big is the file? Can it be FTPed? Do you have a list of the old IDs and how they map to the new IDs?
Todd
Todd Burch