From Second Life Wiki
SetBuoyancy
llSetBuoyancy
Description
Function: llSetBuoyancy( float buoyancy );
Sets the buoyancy of the task or object. Requires physics to be enabled.
if (buoyancy == 0.0) disables
if (buoyancy < 1.0) sinks
if (buoyancy == 1.0) floats
if (buoyancy > 1.0) rises
Caveats
- Wind can cause the prim to drift.
- Unlike some other characteristics, this is cancelled if the script that set buoyancy is removed from the prim.
- This function eats energy to keep the object floating. Large objects many not be able to supply enough energy to keep the object floating.
Notes
Often used to make an object look like gravity does not effect it.