unity rigidbody usegravity set at runtime code example Example: useGravity in unity Rigidbody.useGravity = false;