mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 10:37:02 +00:00
[7564] fixed WorldObject::HasInArc(): must return true if testing self
(cherry picked from commit b3c138ca9d59aff522f8a82cd2e1554fa0fbfc8d) Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
e0c60231bd
commit
8d8da21f95
2 changed files with 5 additions and 1 deletions
|
|
@ -1159,6 +1159,10 @@ float WorldObject::GetAngle( const float x, const float y ) const
|
||||||
|
|
||||||
bool WorldObject::HasInArc(const float arcangle, const WorldObject* obj) const
|
bool WorldObject::HasInArc(const float arcangle, const WorldObject* obj) const
|
||||||
{
|
{
|
||||||
|
// always have self in arc
|
||||||
|
if(obj == this)
|
||||||
|
return true;
|
||||||
|
|
||||||
float arc = arcangle;
|
float arc = arcangle;
|
||||||
|
|
||||||
// move arc to range 0.. 2*pi
|
// move arc to range 0.. 2*pi
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "7563"
|
#define REVISION_NR "7564"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue