- Home /
Animated sprites disappear then rotated on Android
I have in my game a pretty basic animated character, which consists of 2d sprites. All animations are done inside Unity 5. Everything works fine then tested in editor or windows standalone. But then the game runs on android some sprites of my character become invisible.
I do not animate isActive property anywhere and it is always checked. Now, I found out that the disappearing ones are only the sprites that have their rotation animated. If I delete rotation keyframes or set their values to zero, these sprites are visible, but even if the slightest rotation value is added, like 0.1, I get the same problem.
Can someone point out where the problem may be?
hi, I have the same problem ... even in a simple scene (plane and a rotating cube) ... when the cube is starting to rotate the geometry disapears !! and my player starts falling .... ... in the editor everthing is working fine but when I try it out with android in my vrGear the problem occurs.
... this problem only occurs when the rotation is animated a rotation via script is working fine
Answer by orcsworth · Jan 22, 2016 at 11:00 AM
I found the solution, that solves the problem on my testing devices. The problem seems to be the rotation keys interpolation mode - euler angles.
If I right click the rotation channel in animation editor panel tree view and switch interpolation mode to quaternion, the rotation starts to work as expected from it on android devices. This works with Unity version 5.3.0f4.
Thank you!!! This worked 100% for me for the same problem.
Can confirm this too, changing the interpolation for each object in the animation to Quaternion solved the problem on Android devices. Thank you, I've been looking at this problem for two days now.
Answer by windclose · Jan 21, 2016 at 11:19 AM
I have suffered this problem today. When animate the sprite with rotation, the sprite will disappear on Android device.
My unity version is 5.3.1f1.
I create a test project, And make the animation with rotation in 5.2.3p1, It work perfectly on Android device.
Then I open the test project in 5.3.1f1, build , It works perfectly on Android device.
When I remake the animation in 5.3.1f1, Sprite dissappeared!!
Conclusion: It's a Unity's animation create tool bug.
Temporary solution: U can make animation in lower version Unity and import it in to the 5.3.1f1, and the rotation animation will work.
Interesting. Have you tried comparing .anim files YA$$anonymous$$L code to see what is the difference in those animations? This might be the key to the problem.
hi, I have the same problem ... even in a simple scene (plane and a rotating cube) ... when the cube is starting to rotate the geometry disapears !! and my player starts falling .... ... in the editor everthing is working fine but when I try it out with android in my vrGear the problem occurs.
Answer by poony · Feb 05, 2016 at 04:31 PM
I just spent 7 hours trying to debug this before finding this thread. Thank-you for finally putting me out of my misery haha.
Just checking the 2D Sprites I previously created: In v5.2, the rotation defaulted to "Euler Angles (Quaternion Approximation)". In v5.3, the rotation is defaulted to "Euler Angles".
Answer by linxuzi · Feb 05, 2016 at 09:05 PM
fixed in Patch 5.3.2p2
yes.. it seems so.
Animation: Fixed crash when deleting all Euler keys in animation curve. (754373)