- Home /
Other
Asset Bundle vs Resources Question
So I was doing research on the Resources folder and Resources.Load and I learned that Unity said "don't use them" for anything except prototyping your game and to use asset bundles instead. So I started using asset bundles but when I go to build the game, the build fails. I Google this and people say that asset bundles are only for testing in the editor and can't be built? I'm very confused.
Answer by Grish_tad · Nov 08, 2018 at 01:36 PM
Hi @jeungwi. You need to build Asset Bundle for each platform you want to use . If you build windows platform asset bundle, you cant use it in android platform, it will crush your app, or don't show content. You can use Asset Bundles to load 3d objects during run-time from server, or like from StreamingAssets folder.
Any links for info on how to do this? I'm having a hard time finding it, everything I search is giving me a bunch of complicated info that doesn't seem to be able to fix my problem.
I'm creating a single player game on Windows so I'm not doing anything fancy. The reason I need an asset bundle is because I'm trying to save and load Scriptable Objects that are created at runtime.
Example of what I'm doing:
AssetDatabase.CreateAsset(AllCards, "Assets/Data/DeckAsset"); ...(later in the script) AssetDatabase.AddObjectToAsset(CurrentDeck, AllCards);
I just want to be able to build my project again.
EDIT: Oh -_- AssetDatabase is something else, never$$anonymous$$d. Now I have to figure out how to actually create assetbundles at runtime.