Jump Limiter
| LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
Jump Limiter
--BETLOG Hax UTC+10: 20090707 1407 [SLT: 20090706 2107]
My 200-300 ping makes the standard SL jump height kind of annoying.
So this attachment limits that a little.
<lsl> //============================================================== // BETLOG Hax // //---------------------------------- // **** LICENCE START **** // http://creativecommons.org/licenses/by-sa/3.0/ // Attribution licence: // You must: // -Include this unaltered licence information. // -Supply my original script with your modified version. // -Retain the original scripts' SL permissions. [+c/+m/+t] // Or: // -Link to the wiki URL from which you copied this script. // -Document: "Uses parts of <scriptname> by BETLOG Hax" // **** LICENCE END **** //---------------------------------- //========================================================================= default { on_rez(integer param)
{
}
state_entry()
{ llRequestPermissions(llGetOwner(),PERMISSION_TAKE_CONTROLS);
}
attach(key id)
{ if (llGetAttached())
llRequestPermissions(llGetOwner(),PERMISSION_TAKE_CONTROLS);
}
run_time_permissions(integer perm)
{ if(perm & PERMISSION_TAKE_CONTROLS)
llTakeControls(0| CONTROL_UP,TRUE, TRUE);
}
control(key id, integer pressed, integer change)
{ if (pressed & change & CONTROL_UP)
{ if (~llGetAgentInfo(llGetOwner()) & AGENT_FLYING)
{ llSetBuoyancy(-2.0);
llSleep(1.0);
llSetBuoyancy(0.0);
}
}
}
} //========================================================================= </lsl>