summaryrefslogtreecommitdiffstats
path: root/src/Entities/Pawn.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Entities/Pawn.cpp')
-rw-r--r--src/Entities/Pawn.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Entities/Pawn.cpp b/src/Entities/Pawn.cpp
index 9857fa29c..3a8ef8cdf 100644
--- a/src/Entities/Pawn.cpp
+++ b/src/Entities/Pawn.cpp
@@ -82,11 +82,11 @@ void cPawn::Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk)
}
// Spectators cannot push entities around
- if ((!IsPlayer()) || (!static_cast<cPlayer *>(this)->IsGameModeSpectator()))
+ if (!IsPlayer() || (!static_cast<cPlayer *>(this)->IsGameModeSpectator()))
{
- m_World->ForEachEntityInBox(GetBoundingBox(), [=](cEntity & a_Entity)
+ m_World->ForEachEntityInBox(GetBoundingBox(), [this](cEntity & a_Entity)
{
- if (a_Entity.GetUniqueID() == GetUniqueID())
+ if (&a_Entity == this)
{
return false;
}