Locating memory leaks?

I’m having difficulty on finding what is causing a memory leak in my game. If you guys have any information how i might be able to figure out where its coming from that would be great. BTW most of memory is coming from Default and Untracked.

1 Like

Generally, memory leaks are caused by leftover code that doesn’t get picked up by the garbage collector and it gets left in the memory. You should check throughout your code to optimize it and disconnect any connections you don’t need or use the :Destroy() method to properly remove the object from memory if you don’t need it.

I’m by no means an expert on this type of stuff, but there is a wonderful tutorial that explains in-depth what could cause some of your leaks.

https://devforum.roblox.com/t/psa-connections-can-memory-leak-instances/90082

11 Likes