Merge cube gravity

Ok not sure whats going on here, the ball lifts fine on the regular play mode but when I go into the Merge cube it launches it way too high? I’ve tried changing the gravity and the ball weight but no luck. https://cospac.es/AvyD

Hi @Outpost_31,

Because the frame-rate of the web and mobile app are different (especially during MERGE cube AR mode), the physics collisions and velocity are calculated slightly different.

We’re working on ways to make physics behave consistent across all platforms. Please take a look at this edit of your space, which is using real-time physics. Please let me know if this fixed your issue.


Press the remix button to copy the space :slight_smile:

1 Like

Yes it works well, thanks, just wondering what did you change? I noticed you renamed the tabs and changed the gravity to 30, was there something else?

Hi @Outpost_31,

You found most of the changes. In addition to those, I enabled real time physics simulation in the fifth tab via the code Physics.realTime = true;

Ah ok, thanks so much, makes sense now :slight_smile:

Here’s my solution to simulating the gravity on each planet - https://cospac.es/fid5

As you hover/click each planet, the gravity of the environment changes so the ball being represented by its planet falls appropriately. Its looking right to me, but I’d love any feedback. Thanks!

1 Like

Another example that shows a ball falling on earth compared to the moon. If you check my code, you’ll see that the power of this comes in “set gravity pull to” and using the meters per second an object falls on the Earth, Moon, Jupiter or literally anywhere. In the case of Earth, surface gravity pulls at 9.8 meters/second.

Project - https://cospac.es/ghZ4

that awesome, love this idea, thanks for sharing that