mirror of
https://github.com/nillerusr/source-engine.git
synced 2026-08-07 17:29:36 +00:00
vphysics: fix saverestore
This commit is contained in:
@@ -443,7 +443,7 @@ CMeshInstance *CPhysCollideVirtualMesh::BuildLedges()
|
||||
{
|
||||
list.pHull = (byte *)m_pHull;
|
||||
}
|
||||
|
||||
|
||||
if ( list.triangleCount )
|
||||
{
|
||||
m_hMemory = g_MeshManager.CreateResource( list );
|
||||
@@ -532,7 +532,6 @@ CPhysCollide *CreateVirtualMesh( const virtualmeshparams_t ¶ms )
|
||||
|
||||
void DestroyVirtualMesh( CPhysCollide *pMesh )
|
||||
{
|
||||
FlushFrameLocks();
|
||||
delete pMesh;
|
||||
}
|
||||
|
||||
@@ -547,6 +546,7 @@ IVP_SurfaceManager_VirtualMesh::IVP_SurfaceManager_VirtualMesh( CPhysCollideVirt
|
||||
|
||||
IVP_SurfaceManager_VirtualMesh::~IVP_SurfaceManager_VirtualMesh()
|
||||
{
|
||||
FlushFrameLocks();
|
||||
}
|
||||
|
||||
void IVP_SurfaceManager_VirtualMesh::add_reference_to_ledge(const IVP_Compact_Ledge *ledge)
|
||||
|
||||
@@ -209,7 +209,6 @@ void CVPhysPtrUtlVectorSaveRestoreOps::Restore( const SaveRestoreFieldInfo_t &fi
|
||||
for ( int i = 0; i < nObjects; i++ )
|
||||
{
|
||||
void **ppElem = (void**)(&pUtlVector->Element(i));
|
||||
|
||||
pRestore->ReadData( (char *)ppElem, sizeof(void*), 0 );
|
||||
|
||||
int iNewVal = s_VPhysPtrMap.Find( *ppElem );
|
||||
|
||||
@@ -69,7 +69,7 @@ public:
|
||||
void Restore( const SaveRestoreFieldInfo_t &fieldInfo, IRestore *pRestore );
|
||||
|
||||
private:
|
||||
typedef CUtlVector<int> VPhysPtrVector;
|
||||
typedef CUtlVector<intp> VPhysPtrVector;
|
||||
};
|
||||
|
||||
extern CVPhysPtrUtlVectorSaveRestoreOps g_VPhysPtrUtlVectorSaveRestoreOps;
|
||||
|
||||
Reference in New Issue
Block a user