summaryrefslogtreecommitdiff
path: root/src/peds
diff options
context:
space:
mode:
authorJack Powell <jack9267@users.noreply.github.com>2020-08-18 15:57:40 +0100
committerJack Powell <jack9267@users.noreply.github.com>2020-08-18 15:57:40 +0100
commit2dcf31b6c7b76a1fa2b8966d5be673ccddbaeecc (patch)
treeee378aba573615b6204790375f15438139cafcc1 /src/peds
parentc63887637b9cbcefb958d81c9675706db470d818 (diff)
Call CWorld::Remove before the delete, the original game does this and its safer.
Diffstat (limited to 'src/peds')
-rw-r--r--src/peds/Population.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/peds/Population.cpp b/src/peds/Population.cpp
index 0756df38..a1bde005 100644
--- a/src/peds/Population.cpp
+++ b/src/peds/Population.cpp
@@ -117,8 +117,7 @@ CPopulation::Initialise()
void
CPopulation::RemovePed(CPed *ent)
{
- // CPed dtor already does that
- // CWorld::Remove((CEntity*)ent);
+ CWorld::Remove((CEntity*)ent);
delete ent;
}