I’m trying to create a infinite game for iOS that just keeps loading in level blocks at runtime.I have about 40 level blocks as prefabs ( each prefab has about 10 empty object with colliders ) that needs to be loaded in during the gameplay.
I first tried Instantiate/destroy but I was getting a bad lag. After that, I tried instantiating the prefabs at start and using SetActiveRecursively() to activate/deactivate prefabs, but ended up with pretty much same result. I’ve also tried to keep prefabs out of camera, move them in when needed and move them back out. So far, this seems to be the fastest but I’m afraid how it’ll perform later when I have all 40~50 prefabs ready and have them in the scene all the time.
What would be the best way? Is there any other/better way to do this?
Thank you in advance.