[SOLVED] this.entity.setRotation() isnt working

Hello, all,
Im tyring to make dials and was doing some preliminary testing and setRotate just didn’t work, my entity just disappeared. I tested just with normal numbers(I was using variables and script attributes before) and setRotation still didn’t work.

Thanks for any help!

Oh yeah for some reason setting rotation is really weird, I think you need to give it 4 values instead of 3, or something like that.

Oh wait I just remembered you need to use this.entity.setLocalEulerAngles(0, 0, 0);

@ALUCARD thx a lot! Let me try that and get back to you!

Thanks a lot! That works! Do you happen to know why setRotation doesn’t work?

Not Alucard, but setRotation doesn’t work because it expects a quaternion instead of a vec3. Quaternions are another way to implement rotation that works better with animating things but they are stupidly complex.

Thanks @lifeofpain

Your welcome.

I still refuse to believe that “quaternions” actually exist

If you want, you can read. Im not reading this. https://www.3dgep.com/understanding-quaternions/

Im telling you its a conspiracy by big math to prevent us from using the far simpler and far more useful 3 dimensional rotations

“In this article I will attempt to explain the concept of Quaternions in an easy to understand way”

Well, I guess Imma read it today and make a post on it so people can understand it.

quaternions are a lie made up by big math but they allow any possible rotation compared to euler angles which cannot get specific rotations

Honestly I am probably a part of big math, my work causes me to create equations that look like (ARCSIN(1/((√13)/2))). That isnt a joke, I actually needed to create that formula myself just to properly derive an angle of around 33.690067526 degrees.

my condolences

And by “work”, I mean doing what I want to on my free time.