Access Physics manager settings through script

Hi

I'm currently trying to dynamically change the gravity in my scene. I noticed the gravity xyz settings in the physics manager, I can access it ingame through the inspector, but is there a way to access the variables via script?

1 Answer

1

Sure, Physics.Gravity(X, Y, Z).

In Unity 5, above didn't but this syntax worked for me: Physics.gravity = new Vector3(0f, 5f, 0f);