aboutsummaryrefslogtreecommitdiff
path: root/src/game/Object.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-03-28 16:36:54 -0600
committermegamage <none@none>2009-03-28 16:36:54 -0600
commitb72b2a2f5ede384150e586539750dc0e6ce0bd40 (patch)
tree372f85c6986a9695724b3f569cc75bf8756fb899 /src/game/Object.cpp
parent4797684f3b60decf1937b7b920019f8e8251705c (diff)
[7564] fixed WorldObject::HasInArc(): must return true if testing self Author: fgenesis
--HG-- branch : trunk
Diffstat (limited to 'src/game/Object.cpp')
-rw-r--r--src/game/Object.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/game/Object.cpp b/src/game/Object.cpp
index b1523072548..03c10e12cfb 100644
--- a/src/game/Object.cpp
+++ b/src/game/Object.cpp
@@ -1343,6 +1343,10 @@ void WorldObject::GetSinCos(const float x, const float y, float &vsin, float &vc
bool WorldObject::HasInArc(const float arcangle, const WorldObject* obj) const
{
+ // always have self in arc
+ if(obj == this)
+ return true;
+
float arc = arcangle;
// move arc to range 0.. 2*pi