summaryrefslogtreecommitdiffstats
path: root/src/core/Pools.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/Pools.cpp')
-rw-r--r--src/core/Pools.cpp39
1 files changed, 23 insertions, 16 deletions
diff --git a/src/core/Pools.cpp b/src/core/Pools.cpp
index 8e66b049..75536b88 100644
--- a/src/core/Pools.cpp
+++ b/src/core/Pools.cpp
@@ -14,6 +14,13 @@ CObjectPool *&CPools::ms_pObjectPool = *(CObjectPool**)0x880E28;
CDummyPool *&CPools::ms_pDummyPool = *(CDummyPool**)0x8F2C18;
CAudioScriptObjectPool *&CPools::ms_pAudioScriptObjectPool = *(CAudioScriptObjectPool**)0x8F1B6C;
+WRAPPER void CPools::LoadObjectPool(uint8* buf, uint32 size) { EAXJMP(0x4a2550); }
+WRAPPER void CPools::LoadPedPool(uint8* buf, uint32 size) { EAXJMP(0x4a2b50); }
+WRAPPER void CPools::LoadVehiclePool(uint8* buf, uint32 size) { EAXJMP(0x4a1b40); }
+WRAPPER void CPools::SaveObjectPool(uint8* buf, uint32 *size) { EAXJMP(0x4a22d0); }
+WRAPPER void CPools::SavePedPool(uint8* buf, uint32 *size) { EAXJMP(0x4a29b0); }
+WRAPPER void CPools::SaveVehiclePool(uint8* buf, uint32 *size) { EAXJMP(0x4a2080); }
+
void
CPools::Initialise(void)
{
@@ -30,16 +37,16 @@ CPools::Initialise(void)
void
CPools::ShutDown(void)
-{
- debug("PtrNodes left %d\n", ms_pPtrNodePool->GetNoOfUsedSpaces());
- debug("EntryInfoNodes left %d\n", ms_pEntryInfoNodePool->GetNoOfUsedSpaces());
- debug("Peds left %d\n", ms_pPedPool->GetNoOfUsedSpaces());
- debug("Vehicles left %d\n", ms_pVehiclePool->GetNoOfUsedSpaces());
- debug("Buildings left %d\n", ms_pBuildingPool->GetNoOfUsedSpaces());
- debug("Treadables left %d\n", ms_pTreadablePool->GetNoOfUsedSpaces());
- debug("Objects left %d\n", ms_pObjectPool->GetNoOfUsedSpaces());
- debug("Dummys left %d\n", ms_pDummyPool->GetNoOfUsedSpaces());
- debug("AudioScriptObjects left %d\n", ms_pAudioScriptObjectPool->GetNoOfUsedSpaces());
+{
+ debug("PtrNodes left %d\n", ms_pPtrNodePool->GetNoOfUsedSpaces());
+ debug("EntryInfoNodes left %d\n", ms_pEntryInfoNodePool->GetNoOfUsedSpaces());
+ debug("Peds left %d\n", ms_pPedPool->GetNoOfUsedSpaces());
+ debug("Vehicles left %d\n", ms_pVehiclePool->GetNoOfUsedSpaces());
+ debug("Buildings left %d\n", ms_pBuildingPool->GetNoOfUsedSpaces());
+ debug("Treadables left %d\n", ms_pTreadablePool->GetNoOfUsedSpaces());
+ debug("Objects left %d\n", ms_pObjectPool->GetNoOfUsedSpaces());
+ debug("Dummys left %d\n", ms_pDummyPool->GetNoOfUsedSpaces());
+ debug("AudioScriptObjects left %d\n", ms_pAudioScriptObjectPool->GetNoOfUsedSpaces());
printf("Shutdown pool started\n");
delete ms_pPtrNodePool;
@@ -62,12 +69,12 @@ CVehicle *CPools::GetVehicle(int32 handle) { return ms_pVehiclePool->GetAt(handl
int32 CPools::GetObjectRef(CObject *object) { return ms_pObjectPool->GetIndex(object); }
CObject *CPools::GetObject(int32 handle) { return ms_pObjectPool->GetAt(handle); }
-void
-CPools::CheckPoolsEmpty()
-{
- assert(ms_pPedPool->GetNoOfUsedSpaces() == 0);
- assert(ms_pVehiclePool->GetNoOfUsedSpaces() == 0);
- printf("pools have beem cleared \n");
+void
+CPools::CheckPoolsEmpty()
+{
+ assert(ms_pPedPool->GetNoOfUsedSpaces() == 0);
+ assert(ms_pVehiclePool->GetNoOfUsedSpaces() == 0);
+ printf("pools have been cleared\n");
}