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

I have a tool that makes parts, but the parts sometimes falls and sometimes dont. Why?

Asked by 7 years ago

This is the script the tool goes through:

local tool = script.Parent.Parent
local part = tool.Handle

script.Parent.Parent.Activated:connect(function()
    local meteor = Instance.new("Part")
    meteor.Parent = game.Workspace
    meteor.Size = Vector3.new(10,10,10)
    meteor.Shape = "Ball"
    meteor.CFrame = CFrame.new(part.Position.X, part.Position.Y + 30, part.Position.Z)
    meteor.Anchored = false
end)

Whenever this runs, the ball it makes sometimes stay floating and sometimes not.. Why and how can I fix it.

1 answer

Log in to vote
0
Answered by
cabbler 1942 Moderation Voter
7 years ago

Your script should always spawn an unanchored part. Try to parent the meteor after everything else to insure there is no physics glitch.

0
Ok, let me try that y0ucef123 72 — 7y
0
It worked thanks man y0ucef123 72 — 7y
Ad

Answer this question