Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Permissions in child objects

Dominus Skye
Bug Magnet
Join date: 31 Oct 2004
Posts: 54
04-10-2005 20:41
Hi and thanks in advance for the help -)

I am encountering permissions difficulties when attempting to link some objects via llCreateLink.

I have a linked object which obtains change_link permission on rez. When the script causes the delinking of all the prims (which it does fine), I wish to incorporate a change event in one of the former child prims, so it in turn links another prim (and becomes the parent).

I have included a llRequestPermissions in the child object as well, so when the original linked object is rezzed in world, I get asked twice (as I would expect) to grant permissions.

However once the initial object is delinked, and the former child object attempts to link another, I get informed that the Request Permissions option is not set.

So the question I have is, do I need to get the child object of the intial linked set to ask for permission to change links AFTER it has been delinked from the initial set. (i.e. within the changed(int change) event, or can I use it within the initial ON_REZ event when it in turn is already part of a linked set?

Hope this makes sense
Dominus
Jeffrey Gomez
Cubed™
Join date: 11 Jun 2004
Posts: 3,522
04-10-2005 20:55
Perhaps this will shed some light on the subject:

From here and here.

From: someone
llBreakLink(integer linknum)

Delinks the object with the given linknumber linknum (requires permission PERMISSION_CHANGE_LINKS be set).


From: someone
llCreateLink(key target, integer parent)

Attempts to link the object containing the script and target (requires that permission PERMISSION_CHANGE_LINKS be set). If parent == TRUE, the object calling this function will be the parent prim of the new link set, and this prim will become that parent's first child (inserted before any children the parent might have already had).

This function delays the script execution for one second.

The target doesn't require any permission at all. You will be linked - resistance is futile.


Anyway, the child object doing all of this linking will need a script with PERMISSION_CHANGE_LINKS, definitely. The object being added to the link set will need to have modify permissions and/or be owned by you. The root object may also require the permission if it throws an error. That's about it. ;)
_____________________
---
Graham Mondrian
Registered User
Join date: 16 Mar 2005
Posts: 59
04-10-2005 21:08
hi dominus

i think as you say you are requesting permissions for the linked set when you request them for any object of it, are you testing that the permissions are set before setting them? One experiment would be to request the permissions (while the objects are linked) for one and then to test the permissions before requesting them again. If you get no second request then youre asking them of the linked object and you'll have to find a way of asking again or asking before the original linking.