Unofficial LSL Reference

[[functions:lladdtolandpasslist]]


Unofficial LSL reference

User Tools

Login

You are currently not logged in! Enter your authentication credentials below to log in. You need to have cookies enabled to log in.

Login

Forgotten your password? Get a new one: Set new password

This is an old revision of the document!


Function: llAddToLandPassList

llAddToLandPassList(key id, float hours)

Add a person to the allowed residents list of the parcel, either temporarily or permanently.

Sleeps the script for 0.1 seconds.

Parameters

id

The key of the avatar to allow access to.

hours

A float with the number of hours the access allowance will last, or zero to be added permanently to the allowed avatars list.

Notes

  • Sleeps the script for 0.1 seconds.
  • When the addition is not permanent, the maximum time that can be specified is 144 hours (6 days). If more than 144 hours are specified, 144 will be used. If the number of hours specified is 300 or more, the addition won't succeed.
  • Only scripts in objects owned by the land owner can use this function.

Short examples

// Permanently add Doug Linden, whose key is a2e76fcd-9360-4f6d-a924-000000000001,
// to the access allowance list
llAddToLandPassList("a2e76fcd-9360-4f6d-a924-000000000001", 0);

Complete examples

This scripts scans for avatars every hour, and allows allows half an hour of access to a random avatar that is within 60 metres of the object:

llAddToLandPassList-example.lsl
default
{
    state_entry()
    {
        llSensorRepeat("", "", AGENT, 60, PI, 3600);
    }

    sensor(integer num)
    {
        llAddToLandPassList(llDetectedKey((integer)lllFrand(num)), 0.5);
    }
}

See also