Odd Duplication Glitch

I put the print statement at the beginning of the click function. Nothing printed.

Guess what, I fixed it. Somehow.

Putting the click function in this function below worked. For some odd random reason.

editPointsButton.Click:Connect(function()
	if gui.Parent == script then
		for i, v in pairs(game.CoreGui:GetChildren()) do
			if string.find(v.Name, "mainGuiFE2Zipline") then
				gui = script.mainGuiFE2Zipline:Clone()
				v:Destroy()
			end
		end
		gui.Parent = game:WaitForChild("CoreGui")

        -- I put the function here.
	else
		gui.Parent = script
	end
end)

Might’ve had something to do with an unnecessary return?

Likely, thanks for helping though! Most people just reply one time and leave.

1 Like

Sure thing, sometimes you just got to tinker with your code a bit. I was a bit lost with what was causing the issue, but I at least tried!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.