Grizzly Dawson
Registered User
Join date: 24 Sep 2003
Posts: 47
|
02-05-2004 00:05
The text in the LSL manual sounds like any child linked objects should rotate if an object further up the tree rotates. You would expect this for creating obejcts that want to move.
For example if you had a robot and you wanted to make his arm rise up. You would expect (and the LSL docs sound like this should work) to be able to place a llSetRot script in the shoulder joint. When it rotates, you would expect the arm, hand, fingers, etc to rotate as well. But they do not, only the shoulder rotates.
However if you use llTargetOmega in the shoulder the entire arm would spin around as expected, with the shoulder of the robot as the center. Of course this is only good for spinning, not if you want to rotate some specific number of degrees.
Lack of llSetRot not working like llTargetOmega does in moving all child linked objects is bad, because it prevents animation of objects. Objects end up being static in one frozen position.
|
Cornelius Bach
Lord of Typos
Join date: 30 Jul 2003
Posts: 241
|
02-05-2004 09:08
I would think that rotation only that prim would make most sense. For instance you want shoulder rotated and to move the entire arm too? How will the script tell the difference between the arm and the abdomen? your robot would do back flips. 
_____________________
Corny
_________________________________ "I've got to go eat now" Andrew Palmerstone
|
Grizzly Dawson
Registered User
Join date: 24 Sep 2003
Posts: 47
|
02-05-2004 10:14
No, the object plus any child objects, for example
A --> B --> C -->D --> E
For example A-E are linked together with A as the root. If I rotate object C, D and E should follow suit. Object A and B would stay as is since they are farther up the link tree.
It may also be needed to add a boolean switch to the llSetRot function to turn this behavior on and off. So if you really DID want just the shoulder to rotate you could set that param to FALSE and all child linked objects would be ignored.
If llTargetOmega can do it, I don't see why llSetRot couldn't do it as well.
|
Jack Digeridoo
machinimaniac
Join date: 29 Jul 2003
Posts: 1,170
|
02-05-2004 10:30
llTargetOmega is client side. The object isn't actually rotating on the server.
And the only way to get llSetRot to rotate child objects, is to call llSetRot on the parent object.
In a LINK_SET there is only one parent. There's no easy way to do what you want at the moment.
You'd need to use LINK_MESSAGES and rotate and reposition each object in the arm. If I knew the math I would help you out but I have no clue how to do that....
|