It seems like osNpcSetRot is a function used to set the rotation of an NPC (Non-Player Character).
The function takes two parameters:
The first parameter is the NPC that you want to rotate.
The second parameter is the rotation that you want to apply, which is represented as a quaternion.
..so from the code from that link, they're converting Euler angles to a quaternion with the llEuler2Rot function, and then passing that quaternion to osNpcSetRot.
Euler angles can sometimes lead to a problem known as “gimbal lock,” which might be why you’re seeing unexpected behavior.
One thing you could try and test is to only change the Z component of the rotation, and leave the X and Y components as zero. This would look something like this:
Code: Select all
vector xyz_angles = <0.0, 0.0, 185.0>;
This will rotate your NPC around the Z-axis only, which might be what you’re trying to achieve.
Luck, hope you solve it!