diff options
author | LogicParrot <LogicParrot@users.noreply.github.com> | 2017-09-01 21:55:17 +0200 |
---|---|---|
committer | LogicParrot <LogicParrot@users.noreply.github.com> | 2017-09-01 21:55:17 +0200 |
commit | f8b9400713cbb96f61c1515132aa6af99c73d600 (patch) | |
tree | 7ec1ca42f4d23426b103ec89169c4dd57f7c6194 /src/Mobs/PathFinder.cpp | |
parent | merge (diff) | |
download | cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar.gz cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar.bz2 cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar.lz cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar.xz cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.tar.zst cuberite-f8b9400713cbb96f61c1515132aa6af99c73d600.zip |
Diffstat (limited to 'src/Mobs/PathFinder.cpp')
-rw-r--r-- | src/Mobs/PathFinder.cpp | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/src/Mobs/PathFinder.cpp b/src/Mobs/PathFinder.cpp index ca5df2cd6..8fdcb1ae6 100644 --- a/src/Mobs/PathFinder.cpp +++ b/src/Mobs/PathFinder.cpp @@ -10,7 +10,8 @@ cPathFinder::cPathFinder(double a_MobWidth, double a_MobHeight) : m_Path(), m_GiveUpCounter(0), m_NotFoundCooldown(0), - m_DontCare(false) + m_DontCare(false), + m_AvoidSunlight(false) { m_Width = a_MobWidth; m_Height = a_MobHeight; @@ -167,7 +168,7 @@ ePathFinderStatus cPathFinder::GetNextWayPoint(cChunk & a_Chunk, const Vector3d -void cPathFinder::setDontCare(bool a_DontCare) +void cPathFinder::SetDontCare(bool a_DontCare) { m_DontCare = a_DontCare; } @@ -176,7 +177,7 @@ void cPathFinder::setDontCare(bool a_DontCare) -bool cPathFinder::getDontCare() +bool cPathFinder::GetDontCare() { return m_DontCare; } @@ -185,6 +186,24 @@ bool cPathFinder::getDontCare() +void cPathFinder::SetAvoidSunlight(bool a_AvoidSunlight) +{ + m_AvoidSunlight = a_AvoidSunlight; +} + + + + + +bool cPathFinder::GetAvoidSunlight() +{ + return m_AvoidSunlight; +} + + + + + void cPathFinder::ResetPathFinding(cChunk &a_Chunk) { m_GiveUpCounter = 40; |