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

Doesnt remove forcefield. Why? Help please?

Asked by
Proflts 15
9 years ago
script.Parent.Touched:connect(function(hit)
hit.CharacterAdded:connect(function(chr)
    while chr:FindFirstChid("ForceField") ~= nil do wait() end
    local ff = chr:FindFirstChild("ForceField")
    ff:Remove()
    end)
end)

1 answer

Log in to vote
1
Answered by 9 years ago
script.Parent.Touched:connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") ~= nil then
player = hit.Parent
if player:FindFindFirstChild("ForceField") ~= nil
then
player:FindFindFirstChild("ForceField") :remove()
end
end
end)


Ad

Answer this question