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

Is there a way to...?

Asked by 9 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.

Hey, I want to move a part randomly and after 5 secounds make it come back to it's place.I've thought at a way but idk if it will work.

function yeah(mouse)
    x = Instance.new("Part", Workspace)
    --x properties
    x.Touched:connect(function(Part)
        if Part.Parent:FindFirstChild("Humanoid")   == nil then
            y = Part.Position
            Part.Position = Part.Position + Vector3.new(math.random(-3, 3), 0, math.random(-3, 3))
            wait(5)
            Part.Position = y

Thanks!

0
You are missing the endings for your functions. woodengop 1134 — 9y
0
It's not that, I wrote that here not in studio. brokenrares 48 — 9y
0
You have the code, why not test it yourself? Or do you mean, that's all the code you have so far, and you don't know how to finish the script? chess123mate 5873 — 9y

Answer this question