summaryrefslogtreecommitdiffstats
path: root/src/control/PedPlacement.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-07-07 13:09:11 +0200
committeraap <aap@papnet.eu>2019-07-07 13:09:11 +0200
commit53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb (patch)
treefc65a6c40fa719f9d43be9e0e15be79c490135e0 /src/control/PedPlacement.cpp
parentfinished CPhysical (diff)
downloadre3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar.gz
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar.bz2
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar.lz
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar.xz
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.tar.zst
re3-53023eb65bdcde43e341c1ecb7cf0c7f8ee524fb.zip
Diffstat (limited to 'src/control/PedPlacement.cpp')
-rw-r--r--src/control/PedPlacement.cpp40
1 files changed, 0 insertions, 40 deletions
diff --git a/src/control/PedPlacement.cpp b/src/control/PedPlacement.cpp
deleted file mode 100644
index e9a3f7d9..00000000
--- a/src/control/PedPlacement.cpp
+++ /dev/null
@@ -1,40 +0,0 @@
-#include "common.h"
-#include "patcher.h"
-#include "PedPlacement.h"
-#include "World.h"
-
-void
-CPedPlacement::FindZCoorForPed(CVector* pos)
-{
- float zForPed;
- float startZ = pos->z - 100.0f;
- float foundColZ = -100.0f;
- float foundColZ2 = -100.0f;
- CColPoint foundCol;
- CEntity* foundEnt;
-
- CVector vec(
- pos->x,
- pos->y,
- pos->z + 1.0f
- );
-
- if (CWorld::ProcessVerticalLine(vec, startZ, foundCol, foundEnt, true, false, false, false, true, false, nil))
- foundColZ = foundCol.point.z;
-
- // Adjust coords and do a second test
- vec.x += 0.1f;
- vec.y += 0.1f;
-
- if (CWorld::ProcessVerticalLine(vec, startZ, foundCol, foundEnt, true, false, false, false, true, false, nil))
- foundColZ2 = foundCol.point.z;
-
- zForPed = max(foundColZ, foundColZ2);
-
- if (zForPed > -99.0f)
- pos->z = 1.04f + zForPed;
-}
-
-STARTPATCHES
- InjectHook(0x4EE340, &CPedPlacement::FindZCoorForPed, PATCH_JUMP);
-ENDPATCHES