Part moving slanted, rather than straight

Hey guys! why is my bike moving slanted not straight?

local timeForSpeedUpAndSlowDown = .5 --Seconds

local seat = script.Parent
local body = script.Parent.Parent.Part
local LinearVelocity = Instance.new("LinearVelocity", body)

local attachment = Instance.new("Attachment", body)

LinearVelocity.RelativeTo = Enum.ActuatorRelativeTo.Attachment0
LinearVelocity.Attachment0 = attachment

local Gyro = Instance.new("BodyGyro", body)
Gyro.CFrame = body.CFrame
Gyro.MaxTorque = Vector3.new(1,1,1) * 100000

while wait() do

    LinearVelocity.VectorVelocity = body.CFrame.RightVector.Unit * (seat.Throttle * 100) 
    LinearVelocity.MaxForce = (body.AssemblyMass * LinearVelocity.VectorVelocity.Magnitude) / timeForSpeedUpAndSlowDown    
end

Try swapping out the BodyGyro for a AlignOrientation. Deprecated body movers can act funky sometimes, and what I suspect is happening is that its calculating physics Then using the BodyGyro and it wants to make the bike fall but it won’t. but it still applies the falling velocity.

Align Orientation doesnt orient the bike properly

Maybe Attachment0 is not aligned Correctly and is facing the wrong direction.

1 Like