• Login
sketchucation logo sketchucation
  • Login
ℹ️ GoFundMe | Our friend Gus Robatto needs some help in a challenging time Learn More

[REQ] Mix plugins to make windows better

Scheduled Pinned Locked Moved Plugins
11 Posts 4 Posters 2.1k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    bagatelo
    last edited by bagatelo 13 Dec 2009, 17:52

    I would like to mix the functionalities of a plugin with the ones of other, both make similar tasks. If possible, to increase some functions.

    I like the window that plugin make: http://www.crai.archi.fr/RubyLibraryDepot/Ruby/windows.rb

    I adapted him, and I made some alterations, me leaning that this makes a better window.
    However I find a little boring to have to be measuring the wall for then to fill out in field with data of dimensions of the window that I want.

    In that aspect, I find very interesting the possibility to supply the dimensions of the window for simply to click in three points, as that plugin: http://forums.sketchucation.com/viewtopic.php?f=180&t=14394

    Could anybody alter plugin of the @ last to catch dimensions of the window for three clicks how the plugin of doing windows of TOMOT?

    If it was possible to increase the possibility already to create the glasses and the number of the leaves of the window, this would be interesting.

    Please notice the differences in the window that produces the plugin that I altered, and the original. Try!!!

    While the cat's away, the mice will play

    1 Reply Last reply Reply Quote 0
    • T Offline
      toxicvoxel
      last edited by 15 Dec 2009, 22:55

      What could be useful is if there was a generic lib for a series of GET functions (getPt, getPts, GetAngle (with protractor), getDistance, getpath etc.) that could be used by all developers in a consistent way to return select input to functions and dialogs.

      1 Reply Last reply Reply Quote 0
      • B Offline
        bagatelo
        last edited by 22 Dec 2009, 00:52

        I trying to do make myself what I want for this situation, and Sketchup has show me crazy behavior. When I write, for exemplo, 2 * 200, sketchup does not show me 400 as result, but 508. I think Sketchup thinks "2" is inches, not units. What is happening?

        While the cat's away, the mice will play

        1 Reply Last reply Reply Quote 0
        • T Offline
          thomthom
          last edited by 22 Dec 2009, 07:21

          Sketchup's internal units are inches. Always. But 2 * 200.mm 😉

          Thomas Thomassen — SketchUp Monkey & Coding addict
          List of my plugins and link to the CookieWare fund

          1 Reply Last reply Reply Quote 0
          • T Offline
            thomthom
            last edited by 22 Dec 2009, 09:30

            You seem to use a lot of global variables? Any reason for that? could potentially cause conflict.

            But globals aside:

            Sketchup uses inches internally. It assumes that all numbers given is in inches.

            If you type 200 - then SU assumes 200 inches. If you want it to be in mm - then you must type 200.mm
            The numeric class has several methods to convert to and from different units: http://code.google.com/intl/nb/apis/sketchup/docs/ourdoc/numeric.html

            When you type 200.mm - then you get a variable of the Length class: http://code.google.com/intl/nb/apis/sketchup/docs/ourdoc/length.html

            ` x = 200.mm
            7.8740157480315

            x.to_mm
            200.0`

            So you must ensure that at any point, all variables that refer to a measurement unit - that it's made into a Length class so that the unit is represented in SU in inches.

            Thomas Thomassen — SketchUp Monkey & Coding addict
            List of my plugins and link to the CookieWare fund

            1 Reply Last reply Reply Quote 0
            • T Offline
              thomthom
              last edited by 22 Dec 2009, 09:33

              ` wglass = (200.mm - ((8.mm) + ( 1.mm) + (6.mm))) / 3

              2.42782152230971

              wglass.to_mm

              61.6666666666667`

              Thomas Thomassen — SketchUp Monkey & Coding addict
              List of my plugins and link to the CookieWare fund

              1 Reply Last reply Reply Quote 0
              • B Offline
                bagatelo
                last edited by 24 Dec 2009, 18:48

                I make some improvements in the plugin. Now this is more usefull.


                WindowTools.zip

                While the cat's away, the mice will play

                1 Reply Last reply Reply Quote 0
                • B Offline
                  bagatelo
                  last edited by 9 Jan 2010, 09:45

                  Thank you for the answer

                  If I have :
                  $larguraVIDRO = ($larguraJANELA - (( 2 * $larguraFORRA) + ( 2 * $afastaFOLHAS) + ( $larPERFIL * ( $numePORTAS - 1 )))) / $numePORTAS
                  UI.messagebox $larguraVIDRO
                  what means:

                  wglass = (200 - (( 2 * 4) + ( 2 * 0,5) + ( 3 * ( 3 - 1 )))) / 3
                  wglass = (200 - ((8) + ( 1) + (6)) / 3
                  wglass = 61,6666 >>>> this is result that I want, but the Script show me 24.75....

                  How can I correct this expression so that it presents me the correct result?

                  Thanks anyway...

                  While the cat's away, the mice will play

                  1 Reply Last reply Reply Quote 0
                  • D Offline
                    DIEGO-RODRIGUEZ
                    last edited by 9 Jan 2010, 17:51

                    hi. thanks for your plugins.
                    But the first two tools do not work.
                    could repair it?

                    Error: #<NameError: uninitialized constant WindowTools::Jaluminio>
                    C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:24
                    Error: #<NameError: uninitialized constant WindowTools::FOLHAALUMINIO>
                    C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:31
                    C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:24:in `call'
                    C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:24

                    1 Reply Last reply Reply Quote 0
                    • B Offline
                      bagatelo
                      last edited by 9 Jan 2010, 18:26

                      @diego-rodriguez said:

                      hi. thanks for your plugins.
                      But the first two tools do not work.
                      could repair it?

                      Error: #<NameError: uninitialized constant WindowTools::Jaluminio>
                      C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:24
                      Error: #<NameError: uninitialized constant WindowTools::FOLHAALUMINIO>
                      C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:31
                      C:/Archivos de programa/Google/**Google SketchUp 6/**Plugins/WindowTools.rb:24:in `call'
                      C:/Archivos de programa/Google/Google SketchUp 6/Plugins/WindowTools.rb:24

                      Is the very first two tools that I have made. Is strange this situation, because this is working fine for me, but I have Sketchup 7.1, and seems that you have the same version that me. Have you extract de zip file in the right place?
                      I don't understand nothing about RUBY, and yet, I make this improvements...

                      While the cat's away, the mice will play

                      1 Reply Last reply Reply Quote 0
                      • D Offline
                        DIEGO-RODRIGUEZ
                        last edited by 9 Jan 2010, 19:15

                        if. is right.
                        in sketchup 7.1 Functions well.
                        I had only tested on sketchup 6.
                        thanks for answering

                        1 Reply Last reply Reply Quote 0
                        • 1 / 1
                        • First post
                          Last post
                        Buy SketchPlus
                        Buy SUbD
                        Buy WrapR
                        Buy eBook
                        Buy Modelur
                        Buy Vertex Tools
                        Buy SketchCuisine
                        Buy FormFonts

                        Advertisement