0

So, the idea is that there are several dice on the screen and the user needs to shake their phone to roll the dice (or push a button in case they don't have a gyroscope in their phone). The dice should be banging on the screen "walls" like they're in a box or something. At the end all the dice stop on one of their sides. Is there ANY way it can be accomplished with pure React Native/Expo? Any advice is appreciated. And if this one is impossible, can the user at least press the button for the dice to start rolling on the screen?

Christine H.
  • 143
  • 2
  • 7

1 Answers1

0

You can use the sensors using:

https://github.com/react-native-sensors/react-native-sensors

or if you are using Expo:

https://docs.expo.io/versions/latest/sdk/gyroscope/

Dani Gee
  • 413
  • 4
  • 10