Ruby Console
-
I'd like to use the "Angle Between" ruby that I've found, but it computes and outputs in the ruby console and I have no idea how to use it. I looked at the file and have absolutely no clue so, once again, I turn to you kind folks....
KJ
-
Hi KayJay, where did you find the script at? Could you post a link to it so we can see what it does?
Chris
-
angle = vector1.angle_between(vector2)
'angle' is a float that's in radians (note that .radians and .degrees changes between the two formats...)
Use 'angle' as you want...
-
If you open the ruby (.rb) file it'll most likely have instructions on how to use it at the start. (An .rb file is just a text file in disguise, so if windows/os x asks you what to open it with, pick notepad or the os x equivalent.)
If it doesnt, just try installing it and have a look for a menu item afterwards.
If your still not having any luck post it up here and im sure someone would be willing to have a look over it to see how it works.
-
Here's the link to the ruby in question:
http://www.crai.archi.fr/RubyLibraryDepot/Ruby/em_geo_page.htmI have checked the file's text repeatedly as well as all drop-down menus, context menus, and Extension Preference settings and never saw anything I could recognize as instructions. I have the Ruby Console toolbar plugin and have used it to reload the angle between script several times. It tells me it's reloaded but nothing comes up on the colsole when I select the edges that make up the angle I'm trying to measure.
KJ
-
Yes, that is quite an old script, and rather poorly written (in some ways). But if you want to use it, open the Ruby Console (not the "Ruby Web Console" plugin). So go to Window>Ruby Console.
Select your edges and type this in:
ang_betwen_lines
That will start the ruby method on your selected lines and it will output a bunch of stuff tot he ruby console.
Chris
-
Thank you!!!!
KJ
Advertisement