fixes for physics

This commit is contained in:
2026-03-17 01:01:10 +02:00
parent f3ed144fb5
commit 0a506f7185
24 changed files with 179 additions and 74 deletions

View File

@@ -17,7 +17,7 @@ struct CuboidShape_t
float m_fExtentZ;
};
struct TrianglesShape_t
struct TriangleMeshShape_t
{
float *m_pfPositions;
uint32_t m_nPositionCount;
@@ -45,6 +45,7 @@ public:
virtual void SetRotation( Quat vRotation ) = 0;
virtual Vector GetPosition() = 0;
virtual Quat GetRotation() = 0;
virtual void SetType( EPhysicsBodyType eType ) = 0;
virtual void SetGravityScale( float fScale ) = 0;
};
@@ -66,7 +67,7 @@ abstract_class IPhysics
public:
virtual HShape CreateBall( BallShape_t ball ) = 0;
virtual HShape CreateCube( CuboidShape_t ball ) = 0;
virtual HShape CreateTriangles( TrianglesShape_t shape ) = 0;
virtual HShape CreateTriangleMesh( TriangleMeshShape_t shape ) = 0;
virtual void DestroyShape( HShape hShape ) = 0;
virtual HCollider CreateCollider( HShape hShape ) = 0;