I’m trying to make a plane go up using the scroll wheel and a bodygyro. I just don’t know how to rotate a plane to go up, any solutions?
Code:
uis.InputChanged:Connect(function(input) -- Elevator Pitch
if control == "Keyboard" then
if input.UserInputType == Enum.UserInputType.MouseWheel then
if input.Position.Z > 0 then
--up
local Main = Plane:FindFirstChild("Main")
if Main then
Main.Gyro.maxTorque = Vector3.new(0,math.huge,0)
Main.Gyro.CFrame = CFrame.Angles(0,0,math.rad(10))
-- stuck atm, this doesn't work
end
else
--down
local Main = Plane:FindFirstChild("Main")
if Main then
Main.Gyro.maxTorque = Vector3.new(0,math.huge,0)
Main.Gyro.CFrame = CFrame.Angles(0,0,math.rad(-10))
-- stuck atm, this doesn't work
end
end
end
end
end)