I recently upgraded my project from 4.6.3 to 5.0 and it seems to be that the new UI system is not accepting any input anymore although it works fine on Editor. Anyone has that kind of problem before?
Steps to reproduce -
-Create scene using Unity 4.6.3
- Use New UI system like butto and textfield
- Build for android and button is working…
Now Upgrade that project using Unity 5.0 (Problem)
- Play the scene on editor and it’s working
- Build to android and UI system is not working anymore.
Now create new project with Unity 5.0
- Add UI System and play on both editor and android devices and it works fine.
There’s something wrong while upgrading the project and hopefully someone already come up with a solution since I’ve to stop whatever I am doing right now because of UI is not working and spent 2 days for an answer with no luck
One of the quick fix for android is to modify the manifest file. Set the ForwardNativeEventsToDalvik to false and it works back for me atleast for android… Not so sure about iOS though yet.
meta-data android:name=“unityplayer.ForwardNativeEventsToDalvik” android:value=“false”/>
I just ran into the same problem while upgrading from 4.x to 5.
It looks like my UI elements work again if I open up my upgraded project and paste everything in the hierarchy from a “broken” scene into a completely new scene.
Not sure why, but it seems to fix my problem at least.
I am confirming @Joccish about the solution but only copy paste did not do the trick for me.
Create a new scene, create a canvas(it creates and new Eventsystem) and a button. Then go to the main scene and and copy everything instead the canvas and event system to the new canvas. It will work as expected.
GOT IT WORKING!
Ok, so I have tried everything on this thread, nothing worked for me. I did however get everything working perfectly. I shall explain…
I was using a few assets from the store, Android Native Plugin by Stans Assets, Google Mobile Ads SDK by Stans Assets and Google Analytics SDK by Stans Assets.
I completely removed these from the project. Made sure to download the newest versions, and re-imported them. Everything works buttery smooth now. I didn’t have to make a new scene, edit the manifest or copy/paste into a new UI. This makes me think that maybe this is a plugin problem for others, but I am not sure.
Hopefully this helps!
I know it’s a pain to reimport some assets, trust me… this was no easy task.
My symptoms were similar but not exactly the same. However, I suspect that the root cause is the same and that my workaround may work for you too. After upgrading, not only from 4 to 5 but even to newer minor versions within U4 or U5, my hierarchy panel was showing Main Camera and Directional Light only, while it should have shown much more. As a result, nothing was visible after pressing Play.
Last time I encountered the problem was after upgrading to the newest minor version of U5, so I believe it is still worth sharing my experience, although the original question is already 10 months old.
I found two workarounds, of which at least one at a time did the job for me:
- After upgrading, open the project by double clicking on the scene.unity file in Windows Explorer/Finder. This worked in most cases.
- When 1 did not help, I opened the project, went to the project file, found my main scene icon in the project browser panel (Assets/Scenes) and double clicked on it. This one worked for the upgrade to the newest minor version of U5.
No changes of the manifest or reimporting of assets or reinstalling of Plugins was necessary. Worked in both Windows and Mac OS. GOOD LUCK!