1
0
Fork 0
mirror of https://github.com/halpz/re3.git synced 2024-12-23 17:45:28 +00:00

Fix NearPed count going negative

This commit is contained in:
Magnus Larsen 2021-07-12 23:51:28 -07:00 committed by withmorten
parent 523b23339c
commit fb5a207abc

View file

@ -421,6 +421,7 @@ CPed::~CPed(void)
nearPed->m_nearPeds[k] = nearPed->m_nearPeds[k + 1]; nearPed->m_nearPeds[k] = nearPed->m_nearPeds[k + 1];
nearPed->m_nearPeds[k + 1] = nil; nearPed->m_nearPeds[k + 1] = nil;
} }
nearPed->m_nearPeds[ARRAY_SIZE(m_nearPeds) - 1] = nil;
nearPed->m_numNearPeds--; nearPed->m_numNearPeds--;
} else } else
j++; j++;