I'm using the mobile device orentation as player control. so the touch.beta and touch.gamma controls player object move up/down/left/right.
I also would like the game be playable in any situation(lean on sofa, laying on bed) so I set a global variable such as Initial Gamma and Beta so when ever player start/restart the game, the device orientation will adapt how player hold the phone.
I exported the game to Android via CocoonJS, It works fine in most case, but when player laying on bed and hold device face down, the Touch.Gamma will return same value as not face down.
The Gamma range is from -90 to 90, and it cause the control reversed when device is face down.
Any suggestions or solutions will be very helpful <img src="smileys/smiley1.gif" border="0" align="middle" />