summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2021-01-03 20:29:16 +0100
committerNikolay Korolev <nickvnuk@gmail.com>2021-01-03 20:29:16 +0100
commitbec8f6b86c10217c45fd0073c64dfdec2dae98da (patch)
tree4ab6bd377244af4f8323bb6b67799a55cf2638db
parentsmall thing (diff)
downloadre3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar.gz
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar.bz2
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar.lz
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar.xz
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.tar.zst
re3-bec8f6b86c10217c45fd0073c64dfdec2dae98da.zip
-rw-r--r--src/control/Script.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/control/Script.cpp b/src/control/Script.cpp
index b03d8403..d71f532d 100644
--- a/src/control/Script.cpp
+++ b/src/control/Script.cpp
@@ -1673,6 +1673,16 @@ void CMissionCleanup::Init()
}
}
+cleanup_entity_struct* CMissionCleanup::FindFree()
+{
+ for (int i = 0; i < MAX_CLEANUP; i++){
+ if (m_sEntities[i].type == CLEANUP_UNUSED)
+ return &m_sEntities[i];
+ }
+ script_assert(0);
+ return nil;
+}
+
static void SleepThisPed(cleanup_entity_struct* pCleanup, CPed* pPed)
{
printf("*** SLEEPING PED %i %i\n", pCleanup->id, pPed->GetModelIndex());
@@ -1690,16 +1700,6 @@ static void WakeThisPed(cleanup_entity_struct* pCleanup, CPed* pPed)
}
-cleanup_entity_struct* CMissionCleanup::FindFree()
-{
- for (int i = 0; i < MAX_CLEANUP; i++){
- if (m_sEntities[i].type == CLEANUP_UNUSED)
- return &m_sEntities[i];
- }
- script_assert(0);
- return nil;
-}
-
void CMissionCleanup::AddEntityToList(int32 id, uint8 type)
{
cleanup_entity_struct* pNew = FindFree();