From Second Life Wiki
Template:Needs Translation/LSL/de
Template:Needs Translation/LSL/es
Template:Needs Translation/LSL/el
Template:Needs Translation/LSL/he
Template:Needs Translation/LSL/it
Template:Needs Translation/LSL/ko
Template:Needs Translation/LSL/nl
Template:Needs Translation/LSL/hu
Template:Needs Translation/LSL/no
Template:Needs Translation/LSL/da
Template:Needs Translation/LSL/sv
Template:Needs Translation/LSL/tr
Template:Needs Translation/LSL/pl
Template:Needs Translation/LSL/pt
Template:Needs Translation/LSL/ru
Template:Needs Translation/LSL/uk
Template:Needs Translation/LSL/zh-Hans
Template:Needs Translation/LSL/zh-Hant
/LSL
RequestPermissions
llRequestPermissions
Summary
Function: llRequestPermissions( key agent, integer perm );
Ask agent for permission to run certain classes of functions.
| • key
| agent
| –
| avatar UUID that is in the same region
|
|
| • integer
| perm
| –
| Permission mask (bitfield containing the permissions to request).
|
|
Script execution continues without waiting for a response. When a response is given, a
run_time_permissions event is put in the event queue.
Caveats
- A dialog is presented to the agent to grant these permissions except when granted automatically as shown in the table above.
- If object is attached to agent, "automatic" permissions are granted without notification upon request.
- Permissions persist across state changes.
- Regardless of whether granting is automatic, you should always use the run_time_permissions event. Granting permissions takes time, and you shouldn't assume it's completed until the run_time_permissions handler gets invoked.
- Permissions do not accumulate.
- It is currently not possible to request no permissions at all (see Issues below); as a workaround llResetScript can be used.
- Scripts may hold permissions for only one agent at a time. To hold permissions for multiple agents you must use more than one script.
- The result of granting permissions effects the return of llGetPermissions and llGetPermissionsKey immediately despite the run_time_permissions event being queued, or dropped if the object's event queue is full.
- Permission request dialogs never time out.
- If a script makes two permission requests, which ever response is last is considered the granted permissions.
- The viewer limits permission requests from any agent to any other agent to 5 dialogs in 10 seconds
Important Issues
~
Search JIRA for related Bugs
See Also
Events
Functions
Articles