tdelta / SynergyQuest

SynergyQuest is a 2D top-down cooperative multiplayer action-adventure video game using web-based smartphone controllers.
Other
13 stars 1 forks source link

Unintended screen orientation changes when controlling platforms by tilting phone #7

Closed ahbnr closed 4 years ago

ahbnr commented 4 years ago

The D15 levels contain platforms which are controlled using the IMU sensors by tilting the smartphone controller. However, since most phones rotate the display content when tilting the screen beyond a certain threshold, controlling the platform can be quite annoying / the controls be unusable.

We partially resolved this, by locking the screen orientation but this is only allowed by browsers if the controller website is executed in fullscreen. By default, the controller executes in fullscreen and everything is fine, however, users can of course exit the fullscreen mode (e.g. by pressing the "back" button on their phone). Exiting the fullscreen mode also cancels the orientation lock.

The following ideas to improve this situation have been discussed within the team:

  1. Pressing the screen anywhere immediately reactivates fullscreen and orientation lock (a user interaction is required by the browser to enable fullscreen). However, a website which forces itself into fullscreen is often disliked by users.
  2. We detect changes of screen orientation and display a warning which informs the user to reenable fullscreen using the existing fullscreen button

Update: We will implement option 2.