I have been working on a game for a few weeks and everything is going smoothly until I am testing for about 20 minutes and my framerate was getting worse as time went on. After experimenting I found that whenever I equip a tool and unequip a tool, the amount of threads being processed go from 500 to 1300 (or about an 800 increase) and never drop back down so if I spam equip/unequip the tool, the frames drop from 60 to 30 after about 30 times.
I can’t figure out why they never go back down. I can include any code from my game that would be helpful, but I have used every tool in my game and other free model tools to experiment and nothing seems to work. Any idea what could be causing this?
I have recreated my game on a base plate with the essential scripts and everything seems to work fine. I really don’t want to start over, but I don’t know what else to do other then add one bit at a time and test for where the memory is being leaked.