what im trying to do is if the plane is going along and the engine cuts out it wont just stop in mid air but coast along by what i can figure most likly llSetForce and depending on the angle it is moving on the Y axis the force that will be applyed here is the basics of what i was figureing
CODE
integer started;
float liftMax = .975;
float cruiseSpeed = 15;
float speed;
float lift;
///////////////////////////////////////////////
forces()
{
if(started == FALSE)
{
rotation root;
root = llGetLocalRot();
{
if(root.y > 0)
{
// something to dampen the speed and lift
}
else if(root.y < 0)
{
//something to give it speed and lift
}
}
}
}
//////////////////////////////////////////////
timer()
{
forces();
speed = (integer)(llVecMag(llGetVel()) * 1.94384449 + 0.5); // knots
lift = (speed/cruiseSpeed);
if (lift > liftMax) lift = liftMax;
llSetVehicleFloatParam( VEHICLE_BUOYANCY, lift );
}
}
