Hey all,
I’m trying to remove all my performance hiccups in my game right now so I’ve started my 30 day trial of Unity pro and am using the profiler. The results I’ve gotten have helped me get my average frame rate up by a huge amount, pointing me in the direction of some naughty things I’ve forgot that I did in code. However the ‘hiccups’ are entirely still there and the results I’m getting don’t make sense to me.
I can only upload two images for this question, but here are some imgur links if you want to see each of the non-repeating hiccups:
GameView.GetMainGameViewRenderRect
I also made a video, but I’m not sure how useful that will be.
Just by scrubbing through in the profiler, I see on most frames both my CPU and GPU times are below 4ms put together, but once in a while I spike at about 100-200ms on some random function I’m not calling. I’ve played through dozens of times and I get seemingly random internal unity calls popping up at about the same pace (about once per second).
For instance: I have zero cloth simulation in my game and Physics.UpdateSkinnedCloth pops up sometimes?
Any ideas on what this could be or what I can do? I can post code for you guys but I’m not sure how much help it will be since nothing is pointing directly to an area of code.
Edit 1
I’ve made my repo public in case looking at source helps:
https://github.com/xoorath/Farlands
Some of the bigger scripts that are running on update or fixed update include:
Assets/First Person Drifter Controller/Scripts/FirstPersonDrifter.cs
Assets/gameplay/ChunkManager.cs
Assets/graphics/world/ChunkRenderer.cs
The main scene in the root of assets is pretty plain.
Thanks!



Got a character with a cape? It got a rigidbody? If you don't require it, search for the SkinnedCloth component alongside the Skinned Mesh Renderer and if you find one, delete it.
– meat5000Nope, I've got a character with no mesh. It has a Character Controller component, and I've got a bunch of mesh collides in my scene (18 total, lots of verts - 73,000 verts total in the scene). No other physics entities. Edit: if you're curious I can make my github repo public until solved. It's a pretty small code base, all things considered.
– JaredThomsonSounds like a plan.
– meat5000@meat5000 I've updated with the repo url and a brief layout of assets.
– JaredThomsonCrashes my editor BlockSelectItem.prefab and the Main scene file.
– meat5000