Skip to content
lsl.devlsl.devLSL Dev

llReturnObjectsByOwner

function
Function syntax
integer llReturnObjectsByOwner(
  1. key owner,// UUID of the avatar or group whose objects will be returned.
  2. integer scope// OBJECT_RETURN_* scope flag (such as OBJECT_RETURN_PARCEL, OBJECT_RETURN_PARCEL_OWNER, or OBJECT_RETURN_REGION). Values: ReturnObjectsScope
);
Returns
integer
Energy
10

If the script is owned by an agent, PERMISSION_RETURN_OBJECTS may be granted by the owner. If the script is owned by a group, this permission may be granted by an agent belonging to the group’s “Owners” role.

If the return value is negative, it represents an error flag.

Returns an integer that is the number of objects successfully returned to their owners or an ERR_* flag.

How to use
integer result = llReturnObjectsByOwner(NULL_KEY, 0);

Throttled at max parcel land impact capacity region-wide per hour.

ConstantTypeValueDescription
OBJECT_RETURN_PARCELintegerc=return all objects on the same parcel as the script which are owned by 'owner'return all objects on the same parcel as the script which are owned by ‘owner’
OBJECT_RETURN_PARCEL_OWNERintegerc=return all objects owned by 'owner' which are over parcels owned by the owner of the script.return all objects owned by ‘owner’ which are over parcels owned by the owner of the script.
OBJECT_RETURN_REGIONintegerc=return all objects in the region owned by 'owner'return all objects in the region owned by ‘owner’
scope FlagDescription
Return all objects on the same parcel as the script which are owned by owner.
The script must be owned by an estate manager or over a parcel owned by the owner of the script.
Return all objects owned by owner which are over parcels owned by the owner of the script.
Return all objects in the region owned by owner.
The script must be owned by the estate owner or an estate manager.
ConstantTypeValueDescription
ERR_GENERICinteger-1A nebulous and inexplicable error, nothing is known about it.
ERR_PARCEL_PERMISSIONSinteger-2Permission lacked to perform task on specified parcel.
ERR_MALFORMED_PARAMSinteger-3Parameters are malformed.
ERR_RUNTIME_PERMISSIONSinteger-4Script lacks the runtime permission to perform the requested task.
ERR_THROTTLEDinteger-5Task has been throttled. Try again later.
Error FlagsDescription
  • Parcel owner, estate owner and estate managers can not have their objects returned by this method.
  • Objects which are owned by the group the land is set to will not be returned by this method.
  • Objects owned by other groups will be returned to their previous owner if the object is transferable. If not transferable they are deleted.

For group-owned land you may want to explicitly code a group owner’s key into the script as there is no way to determine if a user is a group owner.

Date of Release 18/06/2013

From the issue templates included by the wiki article:

  • SVC-6281 (fs): Shared group inventory
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.