Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --ServerScript
- local part = script.Parent --thay script.Parent bằng đường dẫn đến part
- local x = --toạ độ x part của bạn
- local y = --giá trị nào đó cao hơn toạ độ y part của bạn
- local z = --toạ độ z part của bạn
- local speed = 3 --tốc độ trôi nổi của part, có thể đổi
- local ts = game:GetService("TweenService")
- local ti = TweenInfo.new(speed, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut, math.huge, true, 0)
- local tp = {CFrame = CFrame.new(x, y, z)}
- local tween = ts:Create(part, ti, tp)
- tween:Play()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement