Growing Untracked Memory

Hi there. Recently I noticed my game’s Untracked Memory on the client is constantly growing. It starts at 250 as soon as the game opens and then about an hour later is at 500mb.

I did some googling and it said it could be due to a memory leak. So the past few days I’ve been going through my scripts individually, trying to find the issue. From what I can see there aren’t any connections or things being referenced beyond their scope. I’ve gone as far as to recode some systems aswell just to make sure.

I then saw someone say it could be due to destroying instances, which I do a bit as my game relies on a wide variety of visual effects.

And then someone said you shouldn’t worry about untracked memory as it’s stuff that can be Garbage Collected.

I’m not gonna lie I’m a bit lost at this point, so if anyone could clear things up and give some pointers that’d be much appreciated.

I would suggest using the LuaHeap section in the dev console, and then creating a snapshot, from there you can wait however long you would like, and create a new snapshot to see the difference/increase in objects.

Alternatively, you can use the microprofiler to see if anything is happening there.

1 Like

That was the first thing I tried.

What did it say?