internal static void SetBakedPlaneSize(this PhysicsShapeAuthoring shape, float2 size) { shape.GetPlaneProperties(out var center, out var planeSize, out EulerAngles orientation); var prevSize = math.abs(planeSize); size = math.abs(size); if (math.abs(size[0] - prevSize[0]) < kMinimumChange) { size[0] = prevSize[0]; } if (math.abs(size[1] - prevSize[1]) < kMinimumChange) { size[1] = prevSize[1]; } planeSize = size; shape.SetPlane(center, planeSize, orientation); }