if (spatial instanceof TerrainQuad) {
Boolean bool = spatial.getUserData(UserData.JME_PHYSICSIGNORE);
if (bool != null && bool.booleanValue()) {
continue; // go to the next child in the loop
}
TerrainQuad terrain = (TerrainQuad) spatial;
Transform trans = getTransform(spatial, realRootNode);
shape.addChildShape(new HeightfieldCollisionShape(terrain.getHeightMap(), trans.getScale()),
trans.getTranslation(),
trans.getRotation().toRotationMatrix());
} else if (spatial instanceof Node) {
createCompoundShape(realRootNode, (Node) spatial, shape, meshAccurate, dynamic);
} else if (spatial instanceof TerrainPatch) {
Boolean bool = spatial.getUserData(UserData.JME_PHYSICSIGNORE);
if (bool != null && bool.booleanValue()) {
continue; // go to the next child in the loop
}
TerrainPatch terrain = (TerrainPatch) spatial;
Transform trans = getTransform(spatial, realRootNode);
shape.addChildShape(new HeightfieldCollisionShape(terrain.getHeightMap(), terrain.getLocalScale()),
trans.getTranslation(),
trans.getRotation().toRotationMatrix());
} else if (spatial instanceof Geometry) {
Boolean bool = spatial.getUserData(UserData.JME_PHYSICSIGNORE);
if (bool != null && bool.booleanValue()) {