sketchucation logo sketchucation
    • Login
    1. Home
    2. hpnisse
    3. Posts
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
    H
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 7
    • Posts 101
    • Groups 1

    Posts

    Recent Best Controversial
    • RE: Sketchy Physics help :O

      Hello!!

      I don´t know really how to do that fully functional.
      But you can change so the value always start at 0 (zero), but the slider will be in the middle as always.

      **Go to this folder that contain the physics files: Standard: "C:\Program Files (x86)\Google\Google SketchUp 8\Plugins\SketchyPhysics3"
      Then open the "ControllerCommands.rb" file with a text editor or something like that! (ex. notepad in Windows)
      Scroll down to line "11", probably you don´t have to scroll.

      The line: def slider(sname,defaultValue=0.5,min=0.0,max=1.0)#command#
      Change the line to: def slider(sname,defaultValue=0.0,min=0.0,max=1.0)#command#

      Then save and restart Sketchup!
      When you create a slider or motor or anything at all right now, with a slider, and then start it will show 0.0 and nothing will move.
      !BUT the slider itself will be at the middle of the line! Don´t touch it yet!
      Press pause and pull down the sliders to zero, then it will work!**

      /hope this will solve the problem, otherwise, I recommend that you learn to script with "RUBY".
      Perhaps we can help you with the basics, if I get time! Otherwise, I recommend this website!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Sketchy Physics help :O

      Hello!
      You can do the controller-thing in diffrent ways:
      Write this in the controller field.

      slider("NAMEofSLIDER")
      

      When you press play there will be a slider in a box, from value 0 to 1, (it will start on 0.5)

      key("SOMEkey")
      

      If you change "SOMEkey" to "W" for example, then when you press "W" it will be the same as the slider put to 1 (one)

      getVar("SomeText")
      

      This is used when you will programming the model to do diffrent stuffs, it´s a little more difficult to explain.

      hope this will work it out for you!

      /hpnisse

      posted in SketchyPhysics
      H
      hpnisse
    • RE: How to create a menu selector or scroll bar

      Hello again!
      I'm glad you liked the "script", and that you got it to work for your model, which by the way was really well done!
      My Sketchup crashes sometimes, I do not know if it has to do with SP3.2 but it usually work out if you have autosave on, then you have something to go back to if it would crash.
      Is there anything else, just ask!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: How to create a menu selector or scroll bar

      Hey!

      I made a model that I think works with your requirements.
      "X" is used to move the menu.
      To see how it works: turn on "View Hidden Group", and the script is in the big box on the side.

      Hope this works. You can add several menu steps if you want that.

      Menu-options.skp

      posted in SketchyPhysics
      H
      hpnisse
    • RE: New Hardware Speed Test & how to really speed it up!

      I did the test today, but today I had no other programs running in the background.
      So the result was the following:

      @unknownuser said:

      [list:2z3c5kg9]OpenGL ON

      Shadow on: ["Time", 3.912, "Frames", 60, "Fps", 15.3374233128834]

      Shadow off: ["Time", 1.054, "Frames", 60, "Fps", 56.9259962049336]

      OpenGL OFF

      Shadow on: ["Time", 60.347, "Frames", 60, "Fps", 0.994249921288548]

      Shadow off: ["Time", 24.993, "Frames", 60, "Fps", 2.4006721882127][/list⭕2z3c5kg9]

      I even tried to hide the edges, but it made ​​minimal difference.
      In order to get exactly 60 frames, I used LazyScript and "endSim ()" command.

      posted in Hardware
      H
      hpnisse
    • RE: Jumpy doors and stuck faucets

      The model is too small, that's why the faucets do not work as it should.
      I enlarged the model to 200%, twice the size.
      Then as I put new ones on "Physics Joints", "Hinge / Servos".
      So now it works model properly.

      sink.skp

      posted in SketchyPhysics
      H
      hpnisse
    • RE: New Hardware Speed Test & how to really speed it up!

      Hello!!
      I did the test as you described. And the result was the following:

      @unknownuser said:

      OpenGL ON

      Shadow off: ["Time", 2.377, "Frames", 64, "Fps", 26.9246949936895]

      Shadow on: ["Time", 5.117, "Frames", 65, "Fps", 12.702755520813]

      OpenGL OFF

      Shadow off: ["Time", 28.666, "Frames", 65, "Fps", 2.26749459289751]

      Shadow on: ["Time", 30.419, "Frames", 65, "Fps", 2.13682238074887]

      The difference is incredible. But OpenGL was active from the beginning, so I've never had that problem.
      The computer specs:

      @unknownuser said:

      Processor Intel(R) Core(TM) i5-2500K CPU @ 3.30GHz

      Minne (RAM) 4,00 GB 7,5
      Grafik Radeon HD 6800 Series 7,8
      Spelgrafik 2807 MB tillgängligt grafikminne 7,8
      Primär hårddisk 123GB ledigt (243GB totalt) 5,9
      Windows 7 Ultimate

      System


      Tillverkare Gigabyte Technology Co., Ltd.

      Modell PH67A-UD3
      Total mängd systemminne 4,00 GB RAM
      Systemtyp 64-bitars operativsystem
      Antal processorkärnor 4

      Lagring (Storage)


      Total mängd hårddiskutrymme 1081 GB

      Diskpartition (C:) 123 GB ledigt (243 GB totalt)
      Diskpartition (D:) 61 MB ledigt (100 MB totalt)
      Diskpartition (E:) 29 GB ledigt (29 GB totalt)
      Diskpartition (F:) 52 GB ledigt (492 GB totalt)
      Diskpartition (G:) 29 GB ledigt (30 GB totalt)
      Diskpartition (H:) 2 MB ledigt (2 MB totalt)
      Diskpartition (I:) 149 GB ledigt (196 GB totalt)
      Medieenhet (J:) CD/DVD
      Diskpartition (K:) 11 GB ledigt (90 GB totalt)
      Medieenhet (P:) CD/DVD
      Medieenhet (Q:) CD/DVD
      Medieenhet (R:) CD/DVD
      Medieenhet (S:) CD/DVD
      Medieenhet (T:) CD/DVD

      Grafik


      Typ av grafikkort Radeon HD 6800 Series

      Total mängd tillgängligt grafikminne 2807 MB
      Dedikerat grafikminne 1024 MB
      Dedikerat systemminne 0 MB
      Delat systemminne 1783 MB
      Grafikkortets drivrutinsversion 8.782.0.0
      Primär bildskärmsupplösning 1920x1080
      DirectX-version DirectX 10

      Everything is copied straight across, so most are in Swedish, but I think is enough to understand anyway.
      Windows and Sketchup version is in the signature

      posted in Hardware
      H
      hpnisse
    • RE: Help with Scissor

      The problem with your models is how they are structured.
      In "SketchyPhysics" there are various shapes:
      default box sphere cylinder cone capsule chamfer convexhull staticmesh

      These are used so the plugin knows how the models looks like.
      The plugin dosn't support hollow holes, and concave objects.

      So to crate a correct model you have to create objects with this shapes above and based on that create hollow objects or concave objects.
      To change the "Shape" of a group you just Right-click on the object and in the bottom there is "SketchyPhysics", it includes: "State","Shape" and some other alternatives.

      Look in the atachments file, it has the basic shapes in diffrent "Shapes", just play around.
      PS. To see the objects mesh, Right-click on the object; "State"; "Show collision". And play the simulation, then it will appear a frame that is the accually mesh.
      And if you see in my last model I created to you, I had used this "Shapes" to create a fully functional model of a scissor!!

      /Its a lot of text, sorry! In this webpage there is a "handbook" and Tips&Trix to use in SketchyPhysics!


      mesh in SP.skp

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Help with Scissor

      Hello again!!
      I think I understand what you want to do!
      So here I made ​​an example:
      I have changed a lot, so that the grouping has improved.
      If you want me to change something or think of something more I'll try to help you as far as the knowledge.
      Scissor2.skp

      P.S. This is translated by Google Translate, so I did not have to translate myself.

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Help with Scissor

      Hello!!
      I see the problems in that model.
      The Physics Hinges you created need to be grouped together with the beams in the scissor.
      Cause if physics joint is't grouped they are static.'
      Scissor2-1.skp
      There you got a file that works!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Pipe/tube

      Should the tube rotate can't you use my method, cause them are always static.
      Then you should use "mptak" method thats will works fine.

      posted in SketchyPhysics
      H
      hpnisse
    • RE: SketchyPhysics3.2 (Dec 2)

      Hey, robint!

      Your chain works perfect when you set the collision state correct in every single object 😄
      Re. my chain 1.skp

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Sketchup 8 and SP crashes.

      Hey!
      I've got the problem that SU8 crashes really often, but I hav'nt say something cause I think that my computer is a bit slow to handle some physics...

      Most crashes happen when I had save right before I start the simulation.
      (Saving to be sure, and start simulation right after = CRASHING)
      Not really often that the SU Crash in middle of a simulation.

      I tested to run physics with no objects or no script, and open Ruby Console...
      Ruby console view this, repeating during the simulation:
      E:/Program Files/Google/Google SketchUp 8/Plugins/SketchyPhysics3/ControllerCommands.rb:1005: warning: don't put space before argument parentheses E:/Program Files/Google/Google SketchUp 8/Plugins/SketchyPhysics3/ControllerCommands.rb:1005: warning: parenthesize argument(s) for future version

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Pipe/tube

      Hello!
      It is actually possible to create tubes in SketchyPhysics. As long the tube can be static and don't should moving in simulation.
      I've created a sample file with "Instructions".
      testing.skp
      To run the simulation press "Play" and then press the red balls that just is Frozen
      The Instructions is as a few scenes just click through them!

      PS!! The file is created with - Sketchup 8 - SketchyPhysics 3.2-Dec2 so if you have SU7 just message and I will upload a SU7.

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Connect & disconnect joint function?

      Thanks so much! I've got it to work with that script!

      posted in SketchyPhysics
      H
      hpnisse
    • Connect & disconnect joint function?

      Hello!
      I got a few problems with scripted-joints in sketchyphysics.
      I've got the function that connect two objects to work, but not disconnect.


      This is the script that I use to connect two objects, and it work really good!

      
      ontouch{|toucher,s,p|
         if key("W")==1
                  connect(toucher,"fixed")
         end
      }
      

      But when I want to disconnect two objects thats connected with the script, it dosn't work.
      I know that there is a function that should do this, disconnect() here is the link, But I can't get it to work!
      So how should I do to create a disconnect script that can be trigger by a key or getVar command like the connect script?
      Thanks!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Copy objects with names?

      Hello again!
      Thanks for the help!

      I had done in another way that works to, it´s a bowling lane (with pins and everything ofcourse), but it is scripted, not mechanical.
      So therefor I need to delete the pins/balls that have been used to copy/emitter new ones, otherwise there will be too much geometry in the model.
      And when the model should erase the pins/balls I've think that it only should erase objects with the name pin (or ball) but, I've figured out another way on the problem.
      But thank's alot for the help, I be back if I got more problems.
      The skechyphysics is awesome!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Copy objects with names?

      I want to do that inside a simulation.
      I've created a model that view 3 box(es?) that have diffrent copy methods.
      Sample Copy names.skpBox1

      onstart{
      copy()
      }
      

      Box2

      Emitter at frame 1
      

      Box3

      Just a sample that are copied outside SketchyPhsyics
      

      So my problem is, when Box1 & 2 copy and emitter the new bodies that is created does'nt have any names?
      How to name this object inside sketchyphysics, cause when it's copy or emitter the script field would be erased to?
      Thanks!

      posted in SketchyPhysics
      H
      hpnisse
    • Copy objects with names?

      Hello!
      I've got a problem. When I should copy an object in sketchup the object Name will follow the new copy.
      But when I copy an object with script copy() or use emitterthe new bodies doesn't have any name, is this a bug or something?
      It would be fine if someone get this to work.
      I've think about it a little, and if there is a script that will name objects that touched it then I got it to work.

      Hope someone understand my english. Thanks!

      posted in SketchyPhysics
      H
      hpnisse
    • RE: Camera help

      Really good that you got it to work! 😄


      Pre-release SP 3.2 if from the topic
      http://forums.sketchucation.com/viewtopic.php?f=61&t=32200
      and the direct downloadlink to SP3.2 (windows installer):
      http://sketchyphysics.googlecode.com/files/SetupSketchyPhysics3.2-Nov1.exe
      This version can support midi music or something, watch that topic. The files that was uploaded there was awesome!

      /hpnisse

      posted in SketchyPhysics
      H
      hpnisse
    • 1 / 1