Screen misaligned after device wake up (Android BUG) My solution
I'm sure those of you who publish to android will know this BUG.
In the midst of playing your game, you let the device sleep. After several seconds you wake it up, the game comes on but... OH NO! What is this I see? The screen has misaligned (camera is out of alignment) and your player thinks very lowly of you for being such a bad developer. There it is, another 1 star nailed on the ranking board.
This bug has been around since june/july 2015 and has been one of the many causes for my game NOT being featured on google play store by the play store's editors/reviewers.
I just thought of a solution to this, not very elegant but it goes basically like this:
Have a detection method in one of your actors that will detect all these:
1) if "touch is not active"
2) if scene camera x position and y position is not at your originally set position
then the execute this behaviour:
after 0.1 sec (do not check run to completion) change the scene camera x and y position to your originally set position.
That's it. Try it out and hopefully this will solve it while we wait for GS to fix this and other problems on Android.