Hey guys. I’ve been banging my head into a wall for the past while, because I can’t seem to rotate a tire by both yaw (y axis) and pitch (x axis, think look vector angularity). Yaw works fine, but pitch only works when the lookVector of the yaw is aligned with the global x axis. When it’s perpendicular for example, it causes the tire to do a barrel roll. I could easily see this was because the cframe was rotating the pitch globally, not respecting the object’s yaw.
local cf = CFrame.Angles(throttle, yaw,0)
This is what I had before trying to fix it. I’m assuming my inept knowledge of how cframe rotation works is the flaw behind this
So I tried
local cf = CFrame.new(position) * CFrame.Angles(0,steer,0)
cf *= CFrame.Angles(throttle,0,0)
and
local cf = CFrame.new(position) * CFrame.Angles(0,steer,0)
cf *= CFrame.fromAxisAngle(cf.RightVector, throttle)
both still rotate the pitch globally!
If any of yall have a clue on how to actually rotate something while respecting its already rotated cframe, please let me know <3
Thanks!