00001
00008
00009
00010
00011
00012
00013 #if COMPILING_MODULE_SIM
00014 #ifndef MOD_SIM_CRAFT_PROXY_HH
00015 #define MOD_SIM_CRAFT_PROXY_HH 1
00016
00017 #include "mod_sim_craft.hh"
00018
00019 namespace mod_sim {
00020
00029 class ProxyCraft : public Craft
00030 {
00031
00032 public:
00033 ProxyCraft( const eCraftModel craftModel, const WorldVertex& position );
00034 ~ProxyCraft();
00035 const string GetName( void ) { return string("ProxyCraft"); }
00036 void Draw( void ) { }
00037 void Reset( void );
00038
00039 void Incorporate( SharedPtr<Aircraft> craft, const string& modelName );
00040 void Cycle( void );
00041 void Animate( void );
00042
00043 void SetPosition( const WorldVertex& position );
00044 WorldVertex GetPosition( void );
00045 SharedPtr<const Matrix> GetMatrix( void );
00046 void SetMatrix( const Matrix& matrix );
00047 void Translate( uint axis, fp inc );
00048 void Rotate( uint axis, Radian rad );
00049 void Rotate( uint axis, Radian rad, bool autoRotate );
00050 void RotateWings( const Degree deg, const bool set = false );
00051 void RotateGloveVanes( const Degree deg, const bool set = false );
00052 void RotateTailplanes( const Degree deg, const bool set = false );
00053 void RotateGears( const Degree deg, const bool set = false );
00054 void ResetRotation( void );
00055 fp GetThrottle( void );
00056 void SetThrottle( const fp throttle );
00057 void IncThrottle( const fp inc );
00058 void SetAutoStep( int autoStep );
00059 void SetAutoRotate( uint axis, Radian radian );
00060
00061
00062 Physics& GetPhysics( void );
00063 fp GetSpeedMach( void );
00064 fp GetMaxMach( void );
00065 void SetSpeedMach( const fp mach );
00066 bool IfStall( void );
00067
00068
00069 void EnableChasePlane( const bool enable = true );
00070 void SyncChasePlane( void );
00071 void RotateChasePlane( uint axis, Radian rad );
00072 void TranslateChasePlane( uint axis, fp inc );
00073 void ResetChasePlane( void );
00074
00075 private:
00076 void InitF14Tomcat( const WorldVertex& position );
00077
00078 public:
00079 vector<SharedPtr<Aircraft> > mCrafts;
00080 bool mAutoRotate;
00081 uint mAutoRotateAxis;
00082 Radian mAutoRotateRad;
00083 };
00084
00085 }
00086
00087 #endif // MOD_SIM_CRAFT_PROXY_HH
00088 #endif // COMPILING_MODULE_SIM