Centripetal Force
-
Actually to correct myself, that code will put out whatever units you have set in your model(meters, inches, centimeters,...), this being due to SU converting units with their built in classes (points, vectors,...)
Now the frame length depends entirely on your models framerate, best way to look that up is opening the Ruby console then running SP for about 500 frames and resetting, the readout should get you a fairly accurate FPS average.
Then just multiply the average fps with speed and you got a unit per second value.The framerate setting in Physics Settings is a bit misleading because it has no direct connection to frames per second, what it defines is how many physics calculation cycles will be made before the model refreshes.
So the default 3 means all the collisions, velocities, torques, positions,... will be calculated 3x and then the models will move.
Setting it higher can serve as a fast forward feature, because all the objects will move by more iterations between frames. -
@unknownuser said:
Well you can display the velocity of an object by putting this code into it's Script field:
ontick{
vector = Geom::Vector3d.new( getVelocity )
logLine(vector.length.to_s)
}I tried selecting "OnTick" for my cone, and putting the script you wrote into the blue box that appeared below it. But it keeps saying the formula does not compile. am I doing something wrong?
Thanks,
--PinkSkink
-
Put the code in the Scripted field. Not the ontick field.
-
I hate to be so bothersome, but I can't seem to find this scripted field anywhere. Is it in the UI for the cone? Perhaps you could give me a screenshot?
Sorry about being so annoying!
--PinkSkink
-
Oh! Thanks, Jay, I need to update my Sketchyphysics, then.
--PinkSkink
-
Hi everyone!
I downloaded the latest version of SketchyPhysics, and everything works great now. I have only one problem. For things to work, my cone must be about a yard in diameter. I actually need it to be more like a few inches. But when I make it that small, the joints and things don't seem to work. It seems like SketchyPhysics is unable to sense certain objects when they are below a certain size. Is there a setting I can change to fix this?
Thank you,
PinkSkink
-
It is a limitation of the physics engine.
There is a setting in the plugins->Sketchy Physics settings dialog that will allow you to adjust world scale. It is still tricky tho. Best to make models big enough so that they work with the default settings.
-
I see. Ok, thanks.
--PinkSkink
-
Just a little update.
Everything is working great, including the worldscale, which i did get to work without glitching. However, the velocities needed to expel the ball seem about 10x too big. I'm wondering, in SketchyPhysics is the default acceleration due to gravity 9.8 m/sec^2(32 ft/sec^2), or is it something else?
--PinkSkink
-
That is more or less what gravity is. All other units are not in any sort of real world scale. If 10x works then its "right".
-
Interesting. Thanks very much!
--PinkSkink
Advertisement