LlGetStartParameter
Looking for the current API? Open the llGetStartParameter reference →
Function notes
- If the script was loaded with llRemoteLoadScriptPin then that start parameter is returned.
- If the containing object was rezzed by llRezObjectWithParams or llRezObject or llRezAtRoot then the return is the on_rez parameter.
- If the containing object was manually rezzed, by dragging from inventory, the start parameter is 0.
Return value notes
Returns an integer that is the script start/rez parameter.
Caveats
- The start parameter does not survive region restarts (SVC-2251) or region change (SVC-3258, crossing or teleport).
- If the script is reset (using llResetScript or other means), the start parameter is set to 0.
Examples
default
{
on_rez(integer param)
{
llOwnerSay("rezzed with the number " + (string)param);
}
state_entry()
{
integer i = llGetStartParameter();
if (i)
{
llOwnerSay("I was given the number " + (string)i + " when I was rezzed");
}
else
{
llOwnerSay("rezzed from inventory (or rezzed/loaded with 0)");
}
}
}See also: functions
See also: events
Known issues
SVC-2251: llGetStartParameter returns zero after sim restart
SVC-3258: llGetStartParameter returns zero after change of region
Original wiki source
Some wiki templates and tables need their original context. View this article on the Second Life Wiki. Technical wording and examples are retained from the source; historical guidance may differ from current behavior.