From 7b23225006f8c942f670521f96c02d061600192d Mon Sep 17 00:00:00 2001 From: megamage Date: Sat, 8 Nov 2008 09:03:56 -0600 Subject: [svn] Disable LOS check in canSeeOrDetect. It has been proved that CPU cannot sustain so much calculation. --HG-- branch : trunk --- src/game/Creature.cpp | 3 ++- src/game/Player.cpp | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp index 14ebf19b94c..2dc48cdefc0 100644 --- a/src/game/Creature.cpp +++ b/src/game/Creature.cpp @@ -1529,7 +1529,8 @@ bool Creature::canSeeOrDetect(Unit const* u, bool detect, bool inVisibleList) co } // Now check is target visible with LoS - return u->IsWithinLOS(GetPositionX(),GetPositionY(),GetPositionZ()); + //return u->IsWithinLOS(GetPositionX(),GetPositionY(),GetPositionZ()); + return true; } bool Creature::IsWithinSightDist(Unit const* u) const diff --git a/src/game/Player.cpp b/src/game/Player.cpp index 8699296e75d..4b4f444471c 100644 --- a/src/game/Player.cpp +++ b/src/game/Player.cpp @@ -17284,8 +17284,10 @@ bool Player::canSeeOrDetect(Unit const* u, bool detect, bool inVisibleList) cons return false; } + // If use this server will be too laggy // Now check is target visible with LoS - return u->IsWithinLOS(GetPositionX(),GetPositionY(),GetPositionZ()); + //return u->IsWithinLOS(GetPositionX(),GetPositionY(),GetPositionZ()); + return true; } bool Player::IsVisibleInGridForPlayer( Player const * pl ) const -- cgit v1.2.3