I am trying to figure out how to make the lid of my Martian Cylinder to Unscrew. I gotten the main part of the script finshed and the lid is held on by a weld constant. I tried Cfame again and Vector3 but it didn’t work it made the lid teleport under the map. The video in the bottom is what I am trying to achieve.
Try using hinges, it works very smoothly. To make hinges work you’ll need to attach two attachments to the center of the two parts. Then in the hinge constraint, change the ActuatorType to Motor. Finally in the Motor Properties, change the AngularVelocity to the speed you want to. Hope this helps.
Edit: Also make sure the spinning part isn’t anchor or it will not spin.
You just need to use object-space transformations. Like this
local rs: (RunService) = game:GetService("RunService")
local lid: (BasePart) = script.Parent
while rs.Heartbeat:Wait() do
lid.CFrame = lid.CFrame * CFrame.fromAxisAngle(Vector3.new(1,0,0), math.pi/100) * CFrame.new(0.01,0,0)
end