So I’m making this arcade thing for a game. So for the UI’s to have more properties or events, I made a replica with normal 3D parts and then copy the parts properties to equivalent UI’s in the arcade. The problem is that when I try to rotate a Part, the UI’s don’t rotate the same way and I don’t know why. The UI’s rotate 180° and then return (like an oscillation), but the parts rotate as I want (just one direction and 360°). Here’s a video of what’s happening. (The right side is the part and the left side the UI.) As you can see, even in the properties the value of rotation don’t stay equal.
Any other property such as size, position, colour, etc. is working fine this way.
This is the script I’m using. (this is in the UI with a normal script)
workspace.Part.Changed:Connect(function (property)
if property == "Rotation" then
local xd = workspace.Rocket.Rotation.Y
script.Parent.Rotation = xd
end
end)
Thank you, I’ll answer any questions you may have.
The UI spins 180° degrees and then rotates another 180° but in the opposite direction. It’s like it is oscillating, and i just want it to rotate normally.
Try sizing your part differently, so that the orientation is facing a different direction. Your original code should work, it’s just that the two objects have different starting orientations so it looks off.
I figure it out. Instead of using Rocket.Rotation, I needed to use Rocket.Orientation. I also needed to make the xd negative because it was spining to the opposite side, but now it works. Thank you!