/*! \file track.h \brief Basic level architecture */ #ifndef _TRACK_H #define _TRACK_H #include "stdincl.h" //! The Red Line through a level /** Handles level boundaries, bound movement mapping, camera placement and scripting. To create special levels with special camera movement, rules or whatever, derive from this base class. */ class Track : public BaseObject { private: Uint32 ID; Vector* offset; Vector* end; // Vector* direction; // unity direction vector: it is costy to always recalculate it //Vector* up; // direction where up is ment to be - diffuse in space, eh? //Vector* traverse; // right-left Uint32 nextID; public: Track (); Track (Uint32 number, Uint32 next, Vector* start, Vector* finish); ~Track (); virtual void init(); virtual void postEnter (WorldEntity* entity); // handle coordinate transition in here !!! (when dist < 0 or dist > lasttracklenght) virtual void postLeave (WorldEntity* entity); virtual void tick (float deltaT); virtual void mapCamera (Location* lookat, Placement* camplc); virtual bool mapCoords (Location* loc, Placement* plc); // this should return true if the entity left track boundaries }; #endif /* _TRACK_H */