Don't click here unless you want to be banned.

LSL Wiki : llGetObjectPermMask

HomePage :: PageIndex :: RecentChanges :: RecentlyCommented :: UserSettings :: You are crawling22.us.archive.org
integer llGetObjectPermMask(integer mask)

Returns the requested permission mask for the root object the task is attached to.

Base permissions are the permissions the object has when it was given to the current owner. In theory, no other mask can have more permissions then the base. If they do, then this is a bug in permissions and should be reported.

Mask Value Description
MASK_BASE 0 Get the object's base permissions
MASK_OWNER 1 Get the permissions the current owner has.
MASK_GROUP 2 Get the permissions the object's active group has.
MASK_EVERYONE 3 Get the permissions everyone has on the object.
MASK_NEXT 4 Get the permissions the next owner has.
These are not bitflags! They can not be OR'ed.

Permissions Value (in hex notation) Value (integer) Description
PERM_ALL 0x7FFFFFFF 2147483647 Move/Modify/Copy/Transfer permissions
PERM_COPY 0x00008000 32768 Copy permission
PERM_MODIFY 0x00004000 16384 Modify permission
PERM_MOVE 0x00080000 524288 Move permission
PERM_TRANSFER 0x00002000 8192 Transfer permission

Note: ((PERM_COPY | PERM_MODIFY | PERM_MOVE | PERM_TRANSFER) != PERM_ALL). This is because there may (read as: will) be more permissions in the future.

Example:
default
{
    state_entry()
    {
        integer perm_mask = llGetObjectPermMask( MASK_NEXT);
        if(perm_mask & PERM_MODIFY) llSay(0,"The next owner will have modify permissions.");
        if(perm_mask & PERM_COPY) llSay(0,"The next owner will have copy permissions.");
        if(perm_mask & PERM_TRANSFER) llSay(0,"The next owner will have transfer permissions.");
    }
}


Compare with llGetInventoryPermMask.

Q: How do I set perm masks?
A: As of 1.6.1, you can't. There's a function to do so, llSetObjectPermMask, but it hasn't been completed for security reasons. At some point, it will probably be completed, but there has been no word on when that might happen.


Functions | Permissions | Asset Permissions
Comments [Hide comments/form]
Attach a comment to this page: