Code is not executed after build to android.
I have a finished game which works perfectly on my pc, but after building it to my android phone a certain part of code no longer works, I have tried re-writing it even using different methods but nothing seems to work.
This is the code:
void Update ()
{
currentScore.text = "" + score;
if(BS.dead == true)
{
Invoke("grow", 1f);
}
}
void grow()
{
if(score > InfoScript.info.highscore)
{
InfoScript.info.highscore = score;
}
ACHS.enabled = true;
transform.position = pos;
gameObject.transform.localScale = new Vector3(3f, 12f, 1f);
InfoScript.info.Save();
}
}
BS refers to a script which holds the public bool dead, it is set to false at the start of the game and when u die (by pushing the wrong button) it gets set to true and then this script should be called but just doesn't, I am really at my wits end here so any help would be greatly appreciated. (And remember this works perfectly on my pc only not after it is build to my phone)
Your answer
Follow this Question
Related Questions
Android app installs but does not open on device 0 Answers
When I build my android apk, animation and scripts are breaking. Why is this happening? 0 Answers
Android app unity not working 0 Answers
Why the AddForce fonction works differently on different mobiles ? 1 Answer
*SOLVED* Error writing to IOS file system works on android & editor 1 Answer