- Home /
Physics lag spikes when object below certain height
Hello, I've been trying to solve a frustrating issue with physics lag spikes I've been having. I've searched everywhere and tried all the various suggestions, converted my collision mesh to boxes, etc. However I still had major lag (down to 5fps from 60fps immediately) when any of the objects were falling. Now when moving the object up in the editor to have it fall and check the lag, I discovered that it was completely smooth until it reached a height of 33.5... It isn't colliding into anything, there's no triggers that it is interacting with at that height, there is absolutely no reason for this spike lag. I would greatly appreciate any help I could find with this issue as I haven't found any similar cases after searching.
Export everything you have as a package, and re-import it into a new scene.. if the scene is corrupt, that might be the issue.. less likely but just a shot in the dark.
@xt.xylophone About 50, however all the objects are basically square so there isn't a large amount of polygons, and a few days ago this was working without any lag. Also when there aren't any objects falling there's no lag, however after further testing when I move my scene to start at -50 y, even when there are no objects falling anymore it continues to lag.
@trs9556 Yes even with the camera off there are lag spikes caused.
@Starwalker Will try that and let you know the results as soon as I'm done.
Additional notes if this helps at all.
This is a video recording from when it had been working http://www.youtube.com/watch?v=Ej49aOisUhE
When I spawned multiple buildings even collapsing just one started causing lag, so I tried adjusting time settings and solver iteration down in physics as well as changing the colliders to boxes ins$$anonymous$$d of mesh.
Thank you very much for your responses so far.
If this was working then obviously something else is causing this problem. Have you recently added any scripts or code in a script used? Perhaps you do have a corrupt scene. Can you easily create a new project and rebuilt everything to see if the problem continues?
Your answer
Follow this Question
Related Questions
Unity's Breakout Tutorial Ball Issue. 1 Answer
Manually check collision ? 1 Answer
Colliders coming away from their parent object? 1 Answer
Lag when hitting an object 1 Answer
collision with objects, physics 1 Answer