Optimisation for a noob (who has tried)

Hi Community!

I have been working on a game, as a hobby, and I have run into a block which I cannot overcome. The problem to put it simply is that I am getting a terrible FPS. That is rather vague Im sure but it is, in essence, the problem.

I am going to ask a number of questions and also layout what I have tried.

I use Unity Free Version. My game is a dynamic environment which has thousands of grass, plants, trees etc. I dont use the terrain editor to place the vegetation, I instantiate them as prefabs. They come from the Asset Store: Unity Asset Store - The Best Assets for Game Making.

I get the following stats during runtime:


What stands out for me are Verts and Tris. Perhaps you could point out further issues.

I tried using instant OC for occlusion culling to try improve the performance. Unfortunately, after playing around with the settings a bit, it turned out that it is just not suitable to my game. Objects flickered a bit and some weren’t rendered at all.

I looked into CombineMeshes, and also got hold of the following script: http://wiki.unity3d.com/index.php?title=MeshMerger. Unfortunately I didnt notice any improvement in the performance. The other problem was that the trees in the above mentioned package have 2 materials and thus the script doesnt work for them. I do feel like I could explore mesh merging further. So a question would be, should I pursue this?

Another idea I had was to target a certain FPS (eg 80fps). Then only render objects only 50% of the time by doing gameObject.renderer.enabled=true/false. This would in theory mean that objects would have an effective fps of 40, which would be ok. Im not sure whether this is a decent idea even, but it didnt work as the object just flickers.

My last point is a question about Unitys terrain editor. Why can I place many objects using the terrains: “Place Trees” or “Place Grass” and still achieve a decent fps? Do I have access to trees etc at runtime, like removing or adding objects to the terrain dynamically via script?

Thank you in advanced for anyone who reads through this and can help me; even just a little bit. I know its a lot!

That is a very large number of draw calls. Reducing those is going likely be your best optimization approach: