summaryrefslogtreecommitdiffstats
path: root/src/control
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2020-12-02 10:38:27 +0100
committeraap <aap@papnet.eu>2020-12-02 10:38:27 +0100
commitfba657ff0c77b343ac854a5aed16385a6c77492c (patch)
treec4a125ed77e2b44366bc693dfce2654cc80a795e /src/control
parentsome more GTA_VERSIONs and CGame tidy-up (not much actual memory moving yet) (diff)
downloadre3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar.gz
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar.bz2
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar.lz
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar.xz
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.tar.zst
re3-fba657ff0c77b343ac854a5aed16385a6c77492c.zip
Diffstat (limited to 'src/control')
-rw-r--r--src/control/PathFind.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/control/PathFind.cpp b/src/control/PathFind.cpp
index ecd2d0cb..49e43c81 100644
--- a/src/control/PathFind.cpp
+++ b/src/control/PathFind.cpp
@@ -1649,10 +1649,18 @@ CPathFind::TestCoorsCloseness(CVector target, uint8 type, CVector start)
DoPathSearch(type, start, -1, target, pNodeList, &DummyResult, 32, nil, &dist, 999999.88f, -1);
else
DoPathSearch(type, start, -1, target, nil, &DummyResult2, 0, nil, &dist, 50.0f, -1);
+#ifdef FIX_BUGS
+ // dist has GenerationDistMultiplier as a factor, so our reference dist should have it too
+ if(type == PATH_CAR)
+ return dist < 160.0f*TheCamera.GenerationDistMultiplier;
+ else
+ return dist < 100.0f*TheCamera.GenerationDistMultiplier;
+#else
if(type == PATH_CAR)
return dist < 160.0f;
else
return dist < 100.0f;
+#endif
}
void