I have many prefabs objects (65 MB) in an Unity3D project.

My game use 100 different levels with combinations of the prefab objects.

What is better create 100 scenes or create only one scene where the prefab objects are placed with data from a XML?.

Each Scene load your own prefab objects?

Are the prefab objects loaded in the RAM when the scene is loaded or are stored in the hard disk and then loaded in the RAM when come in the scene?

  • 2
    \$\begingroup\$ No need to wonder; benchmark it. \$\endgroup\$ May 19 '15 at 23:25
  • \$\begingroup\$ I am appealing to experience, before benchmark it and I asking about the loading process used by Unity, I do not know and I do not find the specifications of this. \$\endgroup\$
    – esdebon
    May 19 '15 at 23:30
  • \$\begingroup\$ It will be hard to find other people with experience in the performance of your game's unity assets. If you want to know if a change improves your performance, try that change and measure the difference. \$\endgroup\$ May 20 '15 at 13:05
  • \$\begingroup\$ This is sad, I have over 10 years developing games, this is the first time I use Unity3D. When someone asks me about the elementary processes of the other platforms, I happily respond. My question is not about my game, my question is about how Unity3D load the assets, where and when. \$\endgroup\$
    – esdebon
    May 20 '15 at 16:10
  • \$\begingroup\$ You should edit your question to reflect that. Right now it reads like you are asking how to make your game's complicated levels perform their best. That is a question that can only be answered by you. If you want to focus on Unity's internal behavior, trim out the other parts of your question. But after you are done, make sure you are still following the site's scope: gamedev.stackexchange.com/help/on-topic \$\endgroup\$ May 20 '15 at 20:10

The only things "stored" on the HDD, are the Assets. Everything the game needs throughout every runtime will be stored once and for all; prefabs, scripts, sounds, etc..

But indeed it's very tricky to optimize loading prefabs that you won't ultimately need all at once, but will still be loaded into the scene and take lots of RAM space, I recommend watching this.

  • 1
    \$\begingroup\$ Unless you have a gajillion prefabs for a huge scene, this is negligible. Plus, it's all done at startup so just slap a loading screen on there and forget. \$\endgroup\$
    – JPtheK9
    May 20 '15 at 2:17
  • \$\begingroup\$ Instead of just providing a link to an video, include the information you think answers the question in your answer. This doesn't actually answer the question being asked. It sounds more like you're picking apart the semantics of the question (picking on the word "stored"). Check out the other questions being asked in the post and see if you can address those. \$\endgroup\$
    – MichaelHouse
    May 20 '15 at 21:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.