Changeset 3332 in orxonox.OLD for orxonox/branches/parenting/src/track_manager.h
- Timestamp:
- Jan 4, 2005, 3:51:32 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/parenting/src/track_manager.h
r3331 r3332 33 33 ~TrackElement(void); 34 34 35 TrackElement* findByID(unsigned int trackID); 36 37 bool isFresh; //!< If no Points where added until now 35 38 bool isSavePoint; //!< If the first node is a savePoint 36 39 bool isFork; //!< If the first node is a Fork … … 41 44 CurveType curveType; //!< The CurveType this will have. 42 45 int nodeCount; //!< The count of points this TrackElement has. 46 char* name; //!< A name for the Trac. 43 47 Curve* curve; //!< The Curve of this TrackElement 44 48 int childCount; //!< The number of Children This TrackElement has. … … 56 60 <b>1. Initialize it, by setting up the Graph. You can do this by using the following Commands.</b> 57 61 \li workOn(): changes the ID that will be altered through the changes. 58 \li set Type: lets you set the CurveType of the Curve we are Working on. (default is BezierCurve, set this as early as possible, for this uses resources).62 \li setCurveType(): lets you set the CurveType of the Curve we are Working on. (default is BezierCurve, set this as early as possible, for this uses resources). 59 63 \li setLength(): sets the length of the current path in seconds. 60 64 \li addPoint(): adds a point to the Curve. … … 65 69 \li setSavePoint(): Sets a HotPoint into a savePoint. A Savepoint can be used as a rollbackpoint if a Player gets shot. 66 70 67 71 HotPoints and Joins are at the beginning of a TrackElement. \n 72 SavePoints and Forks are at the end of a TrackElement \n 68 73 look out: <b>SAVEPOINTS CAN NOT BE FORKS</b> (but joins), because the condition is really hard to guess if you do not give some impuls. \n 69 74 \n … … 90 95 static TrackManager* singletonRef; //!< There may only be one TrackManager existing. 91 96 TrackElement* firstTrackElem; //!< The first TrackElement that exists. 92 TrackElement* currentTrackElem; 97 TrackElement* currentTrackElem; //!< The TrackElement we are working on. 93 98 float localTime; //!< The time that has been passed since the traveling the Track. 94 99 float maxTime; //!< The maximal time the track has. … … 96 101 97 102 98 TrackElement findTrackElementByID(int trackID);103 TrackElement* findTrackElementByID(unsigned int trackID) const; 99 104 100 105 … … 104 109 105 110 // Methods to change the Path (initialisation) 106 void workOn( int trackID);107 void set Type(CurveType curveType);111 void workOn(unsigned int trackID); 112 void setCurveType(CurveType curveType); 108 113 void setLength(float time); 109 114 void addPoint(Vector newPoint); 110 115 void addHotPoint(Vector newPoint); 111 116 void setSavePoint(void); 112 void fork( int count, ...);113 void forkV( int count, int* trackIDs);114 void condition( int groupID, PathCondition cond); //!< \todo really do this!!115 void join( int count, ...);116 void joinV( int count, int* trackIDs);117 void fork(unsigned int count, ...); 118 void forkV(unsigned int count, int* trackIDs); 119 void condition(unsigned int groupID, PathCondition cond); //!< \todo really do this!! 120 void join(unsigned int count, ...); 121 void joinV(unsigned int count, int* trackIDs); 117 122 118 123 // Methods to calculate the position on the Path (runtime) 119 Vector calcPos( );120 Vector calcDir( );124 Vector calcPos(void) const; 125 Vector calcDir(void) const; 121 126 void tick(float dt); 122 127 void jumpTo(float time);
Note: See TracChangeset
for help on using the changeset viewer.