/*! * @file track.h */ #ifndef _TRACK_H_ #define _TRACK_H_ #include "curve.h" #include "base_object.h" // Forward Definition class PNode; class TiXmlElement; class Track : public BaseObject { public: virtual void loadParams(const TiXmlElement* root); void addPoint(float x, float y, float z); void addPoint(Vector newPoint); void finalize(); inline Vector calcPos() const; inline Vector calcDir() const; void tick(float dt); PNode* getTrackNode(); private: TrackElement* firstTrackElem; //!< The first TrackElement that exists. TrackElement* currentTrackElem; //!< The TrackElement we are working on. CurveType curveType; //!< The CurveType the entire TrackSystem will have. int trackElemCount; //!< The count of TrackElements that exist. PNode* trackNode; //!< The node that is slave to the Track. This node will be moved while update the Track, and must NOT move itself. }; #endif /* _TRACK_H */