3 protected float m_MaximalActionDistanceSq;
4 protected bool m_MustBeAlive;
8 m_MaximalActionDistanceSq = maximal_target_distance * maximal_target_distance;
9 m_MustBeAlive = must_be_alive;
17 Object targetObject = target.GetObject();
18 if ( !player || !targetObject || targetObject == player || !targetObject.IsMan() || !player.IsFacingTarget(targetObject) || ( m_MustBeAlive && targetObject.IsDamageDestroyed() ) )
21 return (
vector.DistanceSq(targetObject.GetPosition(), player.GetPosition()) <= m_MaximalActionDistanceSq );