Question by
Ashton-Benedict · Sep 29, 2020 at 08:03 PM ·
buildassetbundle
Asset Bundle returns null in build
But "levelBundle" DOESN'T return null in the editor and when you Build & Run.
static AssetBundle levelBundle;
public string[] levels;
private void Awake()
{
levelBundle = AssetBundle.LoadFromFile("Assets/AssetBundles/mainlevels");
if (levelBundle)
{
Debug.Log("TEST");
levels = levelBundle.GetAllScenePaths();
}
}
Comment
Your answer
Follow this Question
Related Questions
Is is possible to provide fix in my C# file through AssetBundle for a android Device 0 Answers
Is ther any way to load text after building game 0 Answers
Unity Cloud Build Copy to StreamingAssets folder 0 Answers
Is There Any Way To Build Assets To Same Consistent File? 0 Answers
A game like KendallKylie? 0 Answers