- Home /
Resources.Load not working on android build
Hey, I have a simple battle scene where when I transition to it from the game it should instantiate to armies. I am using Resources.Load to fetch gameObject that instantiate.
This works fine fine in the editor but doesn't work on my android phone, why is this?
If you post a code snippet of what you're trying to load and how?
Answer by abdo400 · Aug 26, 2017 at 06:30 PM
Code:
AI_Prefab = Resources.Load ("troopsPrefabs/" + manager.enemyArmyList [i].Slug);
Does this work?
AI_Prefab = Resources.Load ("troopsPrefabs/" + manager.enemyArmyList[i].Slug, typeof(GameObject)) as GameObject;
assu$$anonymous$$g AI_Prefab is a GameObject and manager.enemyArmyList[i].Slug is a string.
Your answer
Follow this Question
Related Questions
App work in play test mode but not working in android real device 0 Answers
APK can download to phone, but cannot open on device 0 Answers
Unity-Vuforia android app showing only a black screen. Please help me fix it. 3 Answers
APK building problem 1 Answer
How to decrease Android build time and bypass "Compiling Shader Variants" when adding a new scene 0 Answers