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

an error says that "end is too close at line 5" did you forget to close then at line 9?

Asked by 3 years ago



--The Error says "Expected end. (too close then at line 5) Did you forget to close then at line 9"?

local Humanoid = script.Parent.Humanoid script.Parent.Humanoid.Died:Connect(function(died) local tag = Humanoid:FindFirstChild("creator") if tag ~= nil then if tag.value ~= nil then local leaderstats = tag.Value:FindFirstChild ("leaderstats")

        if leaderstats ~= nil then

                leaderstats.Currency.Value = leaderstats.Currency.Value +30

            script:remove()




           end

        script.Parent.Humanoid.Died:Connect(died)
0
Try doing what the error says, it might start magically working brokenVectors 525 — 3y

1 answer

Log in to vote
0
Answered by 3 years ago

Your first if statement is missing an end, try adding one at line 14. These errors aren't useless by the way, listening to them might get you somewhere. Also, please format your code correctly.

Hope this helped.

Ad

Answer this question