Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to rotate a gui then stop at a a certain point?

Asked by 4 years ago

I need help making a GUI rotate smoothly until a certain point then it stops

I have only made a GUI what turns invisible after a certain point but stopping it is too hard.

someone please help?

-- xBenDaiiAlt/xBenDaii

0
Show us your code first, and second, maybe use tweening? sean_thecoolman 189 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago
script.Parent.TextButton.MouseButton1Click:Connect(function() -- connect to a function      when you want this to run
    for i = 0,180, 1 do -- the first number is where it will start the rotation the second is where it will end and the third one is by how many time it will rotate
        wait(0.001) -- make this numbers smaller to make it faster or make it biger to make it slower
        script.Parent.Frame.Rotation = i --your UI that you rotating .Rotation = i
    end
end)
0
Thank you, i finally can make my script thanks to you! xbendaiialt 44 — 4y
Ad

Answer this question