So I have a container, which is 100% height / width size (systemVars.dimensions.viewport). This container has justifyContent: center and alignItems: center.
Inside this container I have a red box with 32x32 size. At first it’s in the middle of the screen. This is correct, cool.
Now I want to move the red box with gyroscope. For example - rotate device to the left will move the ball to the left edge of the device.
Is it possible? I can assign sensorVars.gyroscope.latestValue.x / y to paragraph / title and just display it on the screen, but I can’t find an option to - for example:
- create page vars X=0 and Y=0
- remove / add gyroscope value to those X and Y vars on every change
What’s my use case is just trying to play with sensors - it’s fun