- Home /
Unity installs old build
I recently got an older MacBook as development device and have been having some problems when building on Android devices.
Sometimes, when I build the game on my device, the installed app is an older version. Running old code, opening scenes that are not enabled and such.
I first encountered this when implementing ads for a game. The plugin we used had a test scene containing all the functionality for test purposes. I added the scene to the build and deactivated others and it ran just fine. Afterwards I disabled the test scene and enabled the original scenes, but still after a build and install, the app in the device opened up the test scene. This has continued even after finishing the ads and implementing other things in the game.
Now I started to modify my shop scripts in another project. My modifications broke the shop and I started finding out why. Every now and then the version installed to the device was missing debuglines, or had old ones, and I had to do another build and hope it would be the current version. One time the version was the one before I even broke the shop.
Has anyone else encountered anything like this? I tried googling, but did not find anything relevant.
I have tried two devices(Note 3, Nexus 7) and have two projects, both with this problem. I have tried uninstalling, clearing cache and data, cleaning project, reimport and many combinations of them. Also I am using Git for version handling.
Try to change your version and bundle version code in player settings.
Answer by TCD · Jul 04, 2015 at 01:13 PM
Make sure to press the add current button when building to ensure u don't build an older scene, but the curent one.
Yes I have done that. Also the problem is not restricted to scenes, so I dont think that can be the problem here.
Same problem here, when I build and run the game on my device, the installed app is an older version. Running old code, with old bugs and old camera placements. I don't know what is going on, the game runs fine when testing using the unity remote app.
Nope. I got rid of the macbook shortly after, but have gotten the same issue on multiple devices afterwards. Dont know what causes it or how to get rid of it. Almost always it goes away in time.
Answer by MD_Reptile · Apr 30, 2016 at 11:07 PM
A common problem for me - although you might have different situation:
Your possibly building out to a different folder and not realizing it!
If you ever made a copy of your projects folder, and opened it as a new project, and went to build for the same platform - you may find it "remembers" that you once built out to the old directory, and it will default to building out there again.
Try building to a folder you create on your desktop or somewhere specific, so you can navigate directly there, and make sure your not re-launching an old version of your game!
I have been building for Android and mostly using the build and run button. I have tried building the .apk to a different folder and with different a name, but the problem persists.
Are you 100 percent sure the right scenes are in the build settings?
Thanks bro, @$$anonymous$$D_Reptile. You don't know how much hours I've lost with something so small!!
I know its been 2 years since you posted this, but i did not include the correct scene in the build setting.
Thanks a lot!!!
Your answer
Follow this Question
Related Questions
How to Simulate a Fresh install Android. 1 Answer
Distribute terrain in zones 3 Answers
Android Build on OSX Crashing after "Done" 0 Answers
What does this error even mean? 1 Answer
Build in Gradle 0 Answers