How can I tell where LuaHeap is coming from

When I start the game, LuaHeap is usually relatively low (20-30mb) but as I sit there (AFK) and wait 10-15 minutes, it climbs all the way up to 150mb. This is from doing absolutely nothing in game. I’m aware it can be due to memory leaks, but I have over 200 modules in the game. So I am wondering if there’s a way to actually tell what script in particular, or even what event cause this issue. I’ve tried looking at the microprofiler, but nothing seems off.

This all from a single player server, so nothing else is happening in game. This in turn is causing memory to get quite high (up to 1gb in full servers!!)

Open the developer console, go to memory, on the Client tab look for “PlaceScriptMemory”. Check for any particular memory-high scripts.

The total of all those scripts only sits at about 2mb

Have you tried checking under the “Server” tab?

I heard having the developer console open can cause high memory usage