Jump to content

llAttachToAvatarTemp caveats


Innula Zenovka
 Share

You are about to reply to a thread that has been inactive for 4276 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

A couple of gotchas about llAttachToAvatarTemp of which it's good to be aware (they confused me no end).

First, when an item attaches with llAttachToAvatarTemp changes owner (i.e. when it attaches to you if it doesn't already belong to you) it appears to purge all previously granted permissions, including PERMISSION_ATTACH (even though you've just granted it), so if the item didn't belong to you before attaching, you need to call PERMISSION_ATTACH again if you want to detach it by script.   The permissions are silently granted this time, but you need to call them.   If it belonged to you in the first place, that's not necessary, which is why I got terribly confused about why something would detach from me but not from my alt when she tested my device.

There's now a caveat in the wiki about this.

The second is that if you want to detach stuff in the changed event (e.g. samples that you want to detach when someone leaves the region) it gets into a race condition and things tend to go wrong unless you put a short llSleep into the event before trying to detach the item.

Details over at SLU, where Void and Dari explained what was happening.  

  • Like 1
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 4276 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...