Clone() Glitching

Everytime I clone an object and delete it, it seems to double once I clone again, for example, I cloned a neon part, and after using that function a few times, the neon got brighter and brighter, as if there was multiple parts. It even did it to the original part in the workspace.

image

image

I haven’t found any solution, this is the neon issue

1 Like

I’m going to need to see some code snippets of your function to understand what’s going on.
The first thing that comes to mind however is duplicate connections.

Let me give an example: I have a Gui. Someone opens a page on the Gui, it loads the button connections for that page. I’ve had issues where once a player clicks a button it fires the button like 2-3 times off of one click. I found out the issue was me not properly calling :Disconnect() on the button connections. It duplicated the watches for events every time I opened the page. Do you have your cloning function attached to an event connection? If so, this might be a possibility. Definitely something to look into.

2 Likes

I think this is has to deal with how you’ve organised your workspace

1 Like