<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
On 6/6/12 12:48 AM, Bengt Falke wrote:
<blockquote cite="mid:A5E675C9-9FFE-4945-9CB3-F14C16530416@falke.nu"
type="cite">I am also interested in physics for vehicles mainly
for creating working yacht and for making my free moving scripted
animals to work in a smooth way.
<div>If there is a way I can contribute I will try to do so.</div>
<div><br>
</div>
</blockquote>
Also at the recent OpenSim developers meeting,
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
Andrew Hellershanks said (about llSetTImerEvent minimum time limits)
"Not sure why you would want to use something other [less] than
1.0". I think the developers need to know that there are 1000's of
scripters in SL DESPERATELY trying to find ANY WAY to make simple
things like a fish move smoothly through the water at a constant
velocity. In SL you can usually get timer() events as often as once
every 0.2 seconds, which is not quite often enough for smooth
looking motion. timer events more often would be one way to get
smoother looking motion. I've seen people write scripts that had
abominations like: while (1) { moveit(); llSleep(0.05); } The
OpenSim developers need to throw these guys a bone so they will NOT
DO THAT HERE!<br>
<br>
Of course, LL only recently threw them the
llSetKeyframedMotion() bone. Before that, people tried to use
physics and llMoveToTarget() which was NEVER DESIGNED TO GENERATE
LINEAR MOTION (it is always damped). Although you can play games
with it and find reasonably linear portions of the curve. But that
requires accurate llSetTimerEvent durations to stop the
llMoveToTarget part way through a damped move. And in OpenSim,
llMoveToTarget is damped 9 times faster than SL (mantis issue 5968)
which requires pushing it nine times harder to try to capture a
linear section and even more accurate llSetTimerEvent times to
prevent the object from running away from you...<br>
<br>
The only other way in SL (before llSetKeframedMotion) to get
something to move smoothly at a constant velocity is to make it a
vehicle. Which is sort of like using a 4 ton hydrolic press to
insert thumbtacks in a cork board. And even in SL, the vehicle
functions are really squirrely.<br>
<br>
So the major reason I am testing the OpenSim vehicle routines is
to see if I can find a reliable subset of them, or a set of
workarounds, that will allow me to move a fish smoothly through the
water at a constant velocity.<br>
<br>
So far I have found a few problems and some workarounds:<br>
1) Vehicles crash and burn at the sim boundary, the workaround is to
add code to detect the sim boundary before the vehicle gets there
and prevent it from even getting close. But if llSetTimerEvent is
not accurate, if your timer() event is not called regularly to do
this check, the vehicle runs into the sim boundary and goes crazy.<br>
2) The angular motor rotates around the wrong axes, but you can
workaround that by multiplying your vectors by llGetRot (mantis
issue 6039). I'm guessing that nobody noticed this before because
cars and boats and helicopters are usually horizontal and their
local Z axis is aligned with the region Z axis.<br>
3) The linear motor vector is clamped or projected onto the region
XY plane. (mantis issue 6040) A car or a boat or a helicopter might
never notice this, but with no Z values allowed in linear motors,
how can airplanes glide up or down? Someone please tell me how to
get this to work!<br>
<br>
<br>
</body>
</html>