Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Linking Permissions (llRezObject)

Ipenda Keynes
Registered User
Join date: 14 Apr 2006
Posts: 12
11-27-2006 11:32
Okay, I got the root prim to rez an object from it's inventory, then it asks my permission to link it.

*Most* of the time, the two items get linked, but sometimes I get an error.

More importantly though, can I script it somehow to always have permission to link, so it doesn't ask the owner every time?

Thanks in advance,
-Ipenda Keynes (feel free to IM me inworld with a response, if you'd like)
Talarus Luan
Ancient Archaean Dragon
Join date: 18 Mar 2006
Posts: 4,831
11-27-2006 11:40
What error do you get? Something about them being too far apart to link? If so, then you have to make sure the two objects/prims being linked are within the link distance for it to work. Also, the max number of prims in one object is 31 for physical objects, and 256 for non-physical. Make sure you're not hitting that limit.

If the existing object script has already gotten your permission to link, it shouldn't have to ask again. However, if the rezzed prims are the ones asking, then yes, they have to ask each time, and you have to grant it, because they are each running their code anew from being rezzed, and don't start out with the permissions.
Ipenda Keynes
Registered User
Join date: 14 Apr 2006
Posts: 12
11-27-2006 11:44
I'm just using 2 prims at the moment, 2 meters apart (just until I get the concept down).

So, can I have the root prim ask for permission when it's first rezzed, and have it apply that to any rezzed prims after that?

How-so?
Nynthan Folsom
Registered User
Join date: 29 Aug 2006
Posts: 70
12-01-2006 20:48
Only the script in the root prim needs permission to link. The scripts in the child links don't unless for some reason you want the child links to be able to change the link set, in which case it would be better to have them send link_messages to the root and have it perform the links changes. Also, when you use llRezObject, note that you can't rely on it being rezzed until you get an object_rez event. If you are calling llCreateLink right after the llRezObject, I'd advise you to move it to the object_rez handler instead.