|
Jesse Malthus
OMG HAX!
Join date: 21 Apr 2006
Posts: 649
|
06-05-2006 21:48
Hi all, I'm creating an eyeball that wonders around and approaches people, and as an extra feature, I'd like it to be able to look at people. I've tried using the Rotation on One Axis look-at script on the wiki (under llLookAt), but it seems to only point the "corner" of the eye towards the detected person. Is there any way I can change the "front" of the objects? Or compensate for this rotationally? Any help would be appreciated --Jesse
|
|
Anti Antonelli
Deranged Toymaker
Join date: 25 Apr 2006
Posts: 1,091
|
06-06-2006 00:03
I've been doing something similar, oddly enough - a follower eyeball that only minimally interacts with other people thus far, but looks at me when it's following and looks in other directions when at rest.
I successfully used some of that getRotToPointAxisAt() code; did you notice that it includes a redundant line of code for each axis, presumably for purpose of the example? Look at the 3 instances of llRotLookAt, in typical usage you'd want to comment out 2 of the 3.
|
|
Jesse Malthus
OMG HAX!
Join date: 21 Apr 2006
Posts: 649
|
06-06-2006 08:20
Yes, I did notice that there are redundant lines. I'm only using the X axis code
|
|
Alphazero Sugar
Noob Tube
Join date: 24 Mar 2005
Posts: 60
|
06-06-2006 16:51
Not sure if this is your issue, but I had similar problems with llSensor when my object was built such that the root prim wasn't pointing down the x-axis.
If I resent the root prim's rotation to <0, 0, 0>, the "front" seemed correct.
|