Skip to content
This repository was archived by the owner on Dec 24, 2020. It is now read-only.

Commit 1f6246f

Browse files
committed
Fix CollisionData cooking
(cherry picked from commit 74a8f0f)
1 parent 9b1bef0 commit 1f6246f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

FlaxEngine/API/BinaryAssets/CollisionData.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public void CookCollision(CollisionDataType type, Model model, int modelLodIndex
111111
if (type == CollisionDataType.None)
112112
throw new ArgumentException(nameof(type));
113113

114-
if (Internal_CookCollision(type, model.unmanagedPtr, modelLodIndex, convexFlags, convexVertexLimit))
114+
if (Internal_CookCollision(unmanagedPtr, type, model.unmanagedPtr, modelLodIndex, convexFlags, convexVertexLimit))
115115
throw new FlaxException("Mesh cooking failed. See log to learn more.");
116116
}
117117

@@ -120,7 +120,7 @@ public void CookCollision(CollisionDataType type, Model model, int modelLodIndex
120120
internal static extern void Internal_GetCookOptions(IntPtr obj, out int modelLodIndex, out ConvexMeshGenerationFlags convexFlags, out int convexVertexLimit);
121121

122122
[MethodImpl(MethodImplOptions.InternalCall)]
123-
internal static extern bool Internal_CookCollision(CollisionDataType type, IntPtr model, int modelLodIndex, ConvexMeshGenerationFlags convexFlags, int convexVertexLimit);
123+
internal static extern bool Internal_CookCollision(IntPtr obj, CollisionDataType type, IntPtr model, int modelLodIndex, ConvexMeshGenerationFlags convexFlags, int convexVertexLimit);
124124
#endif
125125
}
126126
}

0 commit comments

Comments
 (0)