Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Sensor in Child of Attached Object?

Sudane Erato
Grump
Join date: 14 Nov 2004
Posts: 413
01-05-2005 05:59
Varying the question of the "Scripts in Attached Objects" thread, I've got a SensorRepeat script running in a Child prim of an attached object. Trying to detect the position and rotation of the avatar that the parent prim is attached to.

The Wiki says that Sensor will detect the avatar to which an object is attached, IF the Sensor is running in a child of the attached object. But, that's exactly what I've got, and the moment the object is attached to the avatar, the Sensor stops detecting that avatar.

Any secrets to this? Or advice of any kind?

Thanks!

Sudane
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
01-05-2005 06:23
Silly question but why does it need to detect the owner?
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Sudane Erato
Grump
Join date: 14 Nov 2004
Posts: 413
01-05-2005 07:12
The script's purpose is to feedback to another script in the attached object the position and rotation of the owner/avatar. Kind of a GPS system. Where am I, and what position am I facing?
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
01-05-2005 13:41
try the root object rotation. llGetRootRotation or something like that?
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Sudane Erato
Grump
Join date: 14 Nov 2004
Posts: 413
01-06-2005 08:21
Thanks for that tip! llGetRootRotation and llGetRootPosition did actually recognize the avatar as the root of an attached object, which is something I did not expect. In most cases, it appears that an attachment imposes limitations on communication functions, so it was a pleasant surprise to discover that these functions worked.

Sudane