Parcels & Regions
Land is divided into regions (simulators), which belong to estates and are split into parcels. Each level has an owner and settings that limit what scripts can do there: whether scripts run, objects can be built, damage is on, or avatars may enter.
Scripts can read information about the land they are on. Changing it, or moderating visitors, needs the object to be owned by the land owner (or the right group, or estate manager).
The sky and water of a parcel or region are covered by Environments; teleporting between places by Avatars.
Concepts
- Parcels have
details,flags, prim counts andlimits,ownersandsalesettings- A script can check whether it is over its owner’s land and who owns the prims on it
- Parcel media and music URLs are set per parcel
- Regions have a
name, a position on the grid,flags, agent counts, performance and simulator data- Regional settings are read by name
- The object hears when its region has just come online
- The
groundcan be read and, with rights,changed
- Moderation is for land owners and managers
Banandpasslists,ejecting, sending home- Returning objects needs
PERMISSION_RETURN_OBJECTS
- Estate managers’ objects can manage the estate access lists for agents and groups
Functions and events
list | llGetParcelDetails(vector pos, list params) |
integer | llGetParcelFlags(vector pos) |
key | llGetLandOwnerAt(vector pos) |
string | llGetRegionName() |
integer | llGetRegionFlags() |
string | llGetEnv(string name) |
key | llRequestSimulatorData(string region, integer data) |
void | llEjectFromLand(key avatar) |
integer | llReturnObjectsByOwner(key owner, integer scope) |
integer | llManageEstateAccess(integer action, key avatar) |
Parcels
Parcel details, flags, prim counts and limits, owners and sale.
More on the Second Life Wiki.
Estates
Estate access lists for agents and groups.
More on the Second Life Wiki.
Scripting Details
Parcel functions
Section titled “Parcel functions”list | llGetParcelDetails(vector pos, list params)Returns a list containing the requested parcel details specified by params (retrieved in the same order) for the parcel at the vector pos. |
integer | llGetParcelFlags(vector pos)Returns an integer bitfield of parcel flags (PARCEL_FLAG_*) for the parcel at the position pos. |
integer | llGetParcelPrimCount(vector pos, integer category, integer sim_wide)Returns an integer representing the total land impact of objects on the parcel at pos in the specified category. If sim_wide is TRUE, returns combined usage for all regional parcels owned by the parcel owner; if FALSE, returns usage for only the specified parcel. |
integer | llGetParcelMaxPrims(vector pos, integer sim_wide)Returns an integer representing the maximum combined land impact (prim limit) allowed for objects on the parcel at pos, determined either for the single parcel or sim-wide based on sim_wide. |
list | llGetParcelPrimOwners(vector pos)Returns a list of up to 100 strides (formatted as [key owner, integer land_impact]) representing owners of objects on the parcel at pos, sorted by owner key. Requires owner-like permissions for the parcel and the script owner's presence in the region. |
key | llGetLandOwnerAt(vector pos)Returns the key (UUID) of the land owner at the vector pos, or NULL_KEY if the land is public. |
integer | llOverMyLand(key id)Returns TRUE if the avatar or object specified by key id is over land owned by the script owner, or FALSE otherwise. |
integer | llSetParcelForSale(integer ForSale, list Options)Sets the parcel the object is on for sale. If ForSale is TRUE, puts the land up for sale using Options (price, buyer, objects included). Setting ForSale to FALSE removes the parcel from sale. Requires parcel ownership and the PERMISSION_PRIVILEGED_LAND_ACCESS permission. Returns an error code or 0 if successful. |
void | llParcelMediaCommandList(list commandList)Controls the playback of movies and other multimedia resources on a parcel or for an agent, using the PARCEL_MEDIA_COMMAND_* settings specified in commandList. |
list | llParcelMediaQuery(list query)Queries the media properties of the parcel containing the script, returning a list of values in the order requested by query. Only works if the object is owned by the landowner or deeded to the land's group. |
void | llSetParcelMusicURL(string url)Sets the streaming audio (music) URL for the parcel containing the object. The object owner must match the landowner or land group. |
string | llGetParcelMusicURL()Returns a string containing the parcel's streaming music (audio) URL. The object owner must also be the land owner (or share the same group deeding). |
Region functions
Section titled “Region functions”string | llGetRegionName()Returns a string containing the name of the current region. |
vector | llGetRegionCorner()Returns a vector (in meters) representing the global grid coordinates of the south-west corner of the current region (Z component is always 0.0). |
integer | llGetRegionFlags()Returns an integer bitfield representing the region flags (REGION_FLAG_*) currently enabled for the region containing the object. |
string | llGetEnv(string name)Returns a string containing the requested regional data specified by name. |
integer | llGetRegionAgentCount()Returns an integer representing the current number of avatars in the region. |
list | llGetAgentList(integer scope, list options)Requests a list of avatar UUID keys for agents currently in the region, limited by scope. Returns a list of keys or a list containing an error message string. |
key | llRequestSimulatorData(string region, integer data)Asynchronously requests data (using a DATA_SIM_* constant) about the region. Triggers a dataserver event and returns a key query handle. |
string | llGetSimulatorHostname()Returns a string containing the hostname of the server machine running the script (e.g., 'sim225.agni.lindenlab.com'). |
float | llGetRegionFPS()Returns a float representing the average region simulator frames per second (FPS). |
float | llGetRegionTimeDilation()Returns a float representing the current physics time dilation of the region, ranging from 0.0 (full dilation / slow) to 1.0 (no dilation / real-world speed). |
float | llGetSimStats(integer stat_type)Returns a float containing the value of the requested region statistic specified by stat_type. |
integer | llEdgeOfWorld(vector pos, vector dir)Checks if the border reached along the vector dir from the vector pos is the edge of the world (i.e., has no neighboring simulator). Returns TRUE if it hits the edge of the world, or FALSE if there is a neighboring simulator. |
void | llModifyLand(integer action, integer brush)Modifies the terrain using the specified land action and brush size (0, 1, or 2, corresponding to 2m x 2m, 4m x 4m, or 8m x 8m). |
integer | llSetGroundTexture(list changes)Changes the painted terrain textures on the region based on changes. The script owner must have estate management rights. Returns an integer status. |
float | llGround(vector offset)Returns a float representing the ground height directly below the prim's position offset by the vector offset. |
void | llGroundRepel(float height, integer water, float tau)Critically damps the object's vertical motion to height (using critical damping timescale tau) if it is within height * 0.5 of the terrain (or water level if water is TRUE). Only works on physics-enabled objects; do not use with vehicles. |
integer | CHANGED_REGION_START = 0x400Region containing this object has just come online. |
Moderation and estate functions
Section titled “Moderation and estate functions”void | llAddToLandBanList(key avatar, float hours)Adds the avatar to the parcel ban list for the specified number of hours. A value of 0 hours adds the avatar indefinitely. Banned users teleporting to the parcel are redirected to a neighboring parcel; the minimum accepted duration is 0.01 hours (approximately 36 seconds). |
void | llRemoveFromLandBanList(key avatar)Removes the specified avatar from the land parcel's ban list. |
void | llResetLandBanList()Removes all blocked residents from the land parcel's ban list. |
void | llAddToLandPassList(key avatar, float hours)Adds the avatar to the land pass list for the specified number of hours (or indefinitely if hours is 0). |
void | llRemoveFromLandPassList(key avatar)Removes the specified avatar from the land parcel's pass/access list. |
void | llResetLandPassList()Removes all residents from the land parcel's access/pass list. |
void | llEjectFromLand(key avatar)Ejects the specified avatar from land/parcels owned by the object's owner (group or resident). |
void | llTeleportAgentHome(key avatar)Teleports the avatar (who must be standing on land owned by the script owner) directly to their designated home location without warning (similar to a God Summons). |
integer | llReturnObjectsByID(list objects)Returns objects specified by the list of UUIDs objects to their owners. Requires the PERMISSION_RETURN_OBJECTS permission, and the script owner must own the parcel or be an estate manager/region owner. |
integer | llReturnObjectsByOwner(key owner, integer scope)Returns objects owned by owner within the specified scope (parcel, parcel owner, or region). Requires the PERMISSION_RETURN_OBJECTS permission, and the script owner must own the parcel or be an estate manager/region owner. |
integer | PERMISSION_RETURN_OBJECTS = 0x10000Runtime permission required to use the llReturnObjectsByID and llReturnObjectsByOwner functions to return objects from parcels. |
integer | llManageEstateAccess(integer action, key avatar)Adds or removes agents from the estate's access or ban lists, or groups from the estate's group access list, specified by the action. Returns TRUE if successful, or FALSE if throttled, if the action/ID is invalid, or if the script owner lacks estate management rights. |
Additional
llGetParcelDetails— parcel details to read, including teleport routingllGetParcelFlags— parcel flagsllGetParcelPrimCount— prim count categoriesllSetParcelForSale— sale parameters and errorsllParcelMediaCommandList— media commands;llParcelMediaQuery— media queriesllReturnObjectsByOwner— scope and errorsllGetRegionFlags— region flagsllRequestSimulatorData— simulator data;llGetSimStats— simulator statsllGetAgentList— scopellModifyLand— actions and brushes;llSetGroundTexture— parametersllManageEstateAccess— estate access actions
Moderation
Section titled “Moderation”Constant groups ReturnObjectsScope 3ReturnObjectsError 5
See also Category Land Moderation
Parcels
Section titled “Parcels”Constant groups ParcelDetailsParam 14ParcelFlag 16ParcelPrimCountCategory 6ParcelSaleParam 3ParcelSaleError 6ParcelTeleportRouting 3ParcelMediaCommand 14ParcelMediaQuery 6
See also Category ParcelCategory Parcel MediaSL Wiki LSL ParcelSL Wiki Script library: region and parcelPlanned Guide: parcel and region scripting rights
Regions
Section titled “Regions”Constant groups RegionFlag 10SimulatorData 3SimulatorStat 27ModifyLandAction 6ModifyLandBrush 3GroundTextureParam 20AgentListScope 3
See also Category RegionSL Wiki LSL Region
Estates
Section titled “Estates”Constant groups EstateAccessParam 6
See also SL Wiki LSL Estate
Related
Section titled “Related”See also Feature EnvironmentsFeature AvatarsFeature Pathfinding