00001 /****************************************************************************** 00002 * Wormux is a convivial mass murder game. 00003 * Copyright (C) 2001-2004 Lawrence Azzoug. 00004 * 00005 * This program is free software; you can redistribute it and/or modify 00006 * it under the terms of the GNU General Public License as published by 00007 * the Free Software Foundation; either version 2 of the License, or 00008 * (at your option) any later version. 00009 * 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU General Public License 00016 * along with this program; if not, write to the Free Software 00017 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA 00018 ****************************************************************************** 00019 * Jet Pack :-) 00020 *****************************************************************************/ 00021 00022 #ifndef JETPACK_H 00023 #define JETPACK_H 00024 00025 #include "weapon.h" 00026 00027 class JetPack : public Weapon 00028 { 00029 private: 00030 double m_x_force; 00031 double m_y_force; 00032 00033 int channel; 00034 00035 // Jetpack fuel. 00036 uint m_last_fuel_down; 00037 00038 public: 00039 JetPack(); 00040 void Reset(); 00041 void HandleKeyEvent(Action::Action_t action, Keyboard::Key_Event_t event_type) ; 00042 void SignalTurnEnd(); 00043 void ActionStopUse(); 00044 00045 protected: 00046 void Refresh(); 00047 void p_Select(); 00048 void p_Deselect(); 00049 bool p_Shoot(); 00050 00051 void GoUp(); 00052 void GoLeft(); 00053 void GoRight(); 00054 void StopUp(); 00055 void StopLeft(); 00056 void StopRight(); 00057 void StartUse(); 00058 void StopUse(); 00059 }; 00060 00061 #endif /* JETPACK_H */