class IPathFollower;
IPathfinder.h
virtual ~IPathFollower();
virtual void Advance(float distance) = 0;
Advances the current state in terms of position - effectively pretending that the follower has gone further than it has.
virtual void AttachToPath(INavPath * navPath) = 0;
This attaches us to a particular path (pass 0 to detach)
virtual bool CheckWalkability(const Vec2* path, const size_t length) const = 0;
Checks ability to walk along a piecewise linear path starting from the current position (useful for example when animation would like to deviate from the path)
virtual void Draw(const Vec3& drawOffset = ZERO) const = 0;
virtual bool GetAllowCuttingCorners() const = 0;
Can the pathfollower cut corners if there is space to do so? (default: true)
virtual float GetDistToEnd(const Vec3 * pCurPos) const = 0;
Returns the distance from the lookahead to the end, plus the distance from the position passed in to the LA if pCurPos != 0
virtual float GetDistToNavType(IAISystem::ENavigationType navType) const = 0;
virtual float GetDistToSmartObject() const = 0;
Returns the distance along the path from the current look-ahead position to the first smart object path segment. If there's no path, or no smart objects on the path, then std::numeric_limits
virtual const PathFollowerParams & GetParams() const = 0;
Just view the params
virtual Vec3 GetPathPointAhead(float dist, float & actualDist) const = 0;
Returns a point on the path some distance ahead. actualDist is set according to how far we looked - may be less than dist if we'd reach the end
virtual void Release() = 0;
virtual void Reset() = 0;
virtual void Serialize(TSerialize ser) = 0;
virtual void SetAllowCuttingCorners(const bool allowCuttingCorners) = 0;
Sets whether or not the pathfollower is allowed to cut corners if there is space to do so. (default: true)
virtual void SetParams(const PathFollowerParams & params) = 0;
virtual bool Update(PathFollowResult & result, const Vec3 & curPos, const Vec3 & curVel, float dt) = 0;
Advances the follow target along the path as far as possible while ensuring the follow target remains reachable. Returns true if the follow target is reachable, false otherwise.