- Home /
The question is answered, right answer was accepted
iOS game freezes at a collision after startup
Hi. Each time i start the game and it detects a collision i see it freeze for 1-2 seconds.This only happens after i just started the game.If i reset the game without closing it with Application.loadlevel this problem is not there anymore.What could cause this problem and how can i fix it? Thank you
Are you perfor$$anonymous$$g any heavy processing inside OnCollisionEnter like resource loading or something?
Is it in build or editor?
it is build on iOS and this only happends the first time i start the game. if i do another collision right after it does not happend and also it does not happend again if i restart the stage
Oh. Still try to check it in editor with mouse based controlling, if possible.
But currently one of the reasons might be iOS is running low on memory and trying to free space for the application causing it to freeze, in this case try to test it on another device. OR if possible, can try to use the profiler to figure out exact issues.
Answer by HarshadK · Sep 26, 2014 at 11:52 AM
You can create a pool of these particle systems where you can store the particle systems so that you do not have to instantiate it every time required.