Alright, so i am making an obby with floating lava, since it is based over a black hole (do not ask). I am using a server-side (plain). You can look at the screenshot of the explorer here.

The script:

local pos = script.Parent.BodyPosition.Position
local curpos = script.Parent.Position
local pos1 = script.Parent.Point1.Position
local pos2 = script.Parent.Point2.Position
local i = true
pos = pos2

while true do
    wait(.1)
    if curpos == pos1 then
        pos = pos2
        i = false
    elseif curpos ==pos2 then
        pos = pos1
    elseif i == true then
        pos = pos1
        i = false
    end
end

Thanks in advance.

Link not working? Try pasting this link into your web bar: https://imgur.com/a/WxzuqGa

NOTE: THIS IS A REPORT.

3 comments

0

you can always try countering gravity if you want to make the thing float

0

Do you want the part to have less gravity, like it's in space?

0

No, just float up and down. Like it's in an obby. (cuz it is)