//========= Copyright © 1996-2005, Valve Corporation, All rights reserved. ============//
//
// Purpose: 
//
// $NoKeywords: $
//=============================================================================//

#ifndef BOT_NAVIGATOR_H
#define BOT_NAVIGATOR_H
#ifdef _WIN32
#pragma once
#endif

#include "bot/bot.h"

class CBotNavigator : public CBotComponent
{
	typedef CBotComponent BaseClass;
public:
	CBotNavigator( CBot *pOuter );

	virtual bool		Move( float flInterval = 0.1 );
	virtual void		MoveTo( Vector goal );

	virtual void UpdateAngles();

	void SetGoal( Vector goal, float tolerance );
	Vector GetGoal() { return m_vGoalPosition; }
	float GetGoalTolerance() { return m_fGoalTolerance; }

private:
	void NormalizeFloatAngle ( float *fAngle ); 

private:
	Vector m_vInternNextGoal;
	bool	m_bReachedInternGoal;

	Vector			m_vGoalPosition;
	float			m_fGoalTolerance;
	bool			m_bGoalReached;
	bool			m_bNewGoal;

	float m_fIdealMoveSpeed;
};


#endif // BOT_NAVIGATOR_H
