mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-05-09 15:26:17 +00:00
JOLT Physics update
adds jolt physics to torque3d
This commit is contained in:
parent
d331731aa1
commit
48312ae20e
16 changed files with 2700 additions and 3 deletions
|
|
@ -2587,11 +2587,15 @@ void MeshRoad::_generateSegments()
|
|||
polylist.triangulate();
|
||||
|
||||
PhysicsCollision *colShape = PHYSICSMGR->createCollision();
|
||||
colShape->addTriangleMesh( polylist.mVertexList.address(),
|
||||
if (!colShape->addTriangleMesh(polylist.mVertexList.address(),
|
||||
polylist.mVertexList.size(),
|
||||
polylist.mIndexList.address(),
|
||||
polylist.mIndexList.size() / 3,
|
||||
MatrixF::Identity );
|
||||
getWorldTransform()))
|
||||
{
|
||||
// failed to create mesh, get out GET OUT NOWWWW
|
||||
return;
|
||||
}
|
||||
|
||||
PhysicsWorld *world = PHYSICSMGR->getWorld( isServerObject() ? "server" : "client" );
|
||||
mPhysicsRep = PHYSICSMGR->createBody();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue