I have a terrain created from a perlin noise in SceneKit, and now I want to add physics to the terrain. However, simply doing terrain.physicsBody = SCNPhysicsBody(type: .static, shape: nil)
results in SceneKit converting the physics shape of the terrain into a convex shape automatically. Now if you put anything onto the terrain, it'll be floating in the air on a plane of the bounding box of the terrain instead of sticking to the ground.
How can I modify the behaviors of SCNPhysicsBody so that it simulates the physics of a terrain?