Changeset 7035 in orxonox.OLD for trunk/src/util
- Timestamp:
- Feb 5, 2006, 11:26:21 PM (19 years ago)
- Location:
- trunk/src/util
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/game_rules.cc
r7020 r7035 26 26 * constructor 27 27 */ 28 GameRules::GameRules(const TiXmlElement root) 29 {} 28 GameRules::GameRules(const TiXmlElement* root) 29 { 30 this->setClassID(CL_GAME_RULES, "GameRules"); 31 } 30 32 31 33 /** … … 38 40 39 41 void GameRules::loadParams(const TiXmlElement* root) 40 {} 42 { 43 BaseObject::loadParams(root); 44 } 41 45 -
trunk/src/util/game_rules.h
r7034 r7035 20 20 21 21 public: 22 GameRules(const TiXmlElement root);22 GameRules(const TiXmlElement* root); 23 23 virtual ~GameRules(); 24 24 25 virtual void loadParams(const TiXmlElement* root );25 virtual void loadParams(const TiXmlElement* root = NULL); 26 26 27 27 -
trunk/src/util/multiplayer_team_deathmatch.cc
r7034 r7035 18 18 19 19 #include "load_param.h" 20 #include "factory.h" 20 21 21 22 … … 23 24 24 25 26 CREATE_FACTORY(MultiplayerTeamDeathmatch, CL_MULTIPLAYER_TEAM_DEATHMATCH); 27 28 25 29 /** 26 30 * constructor 27 31 */ 28 MultiplayerTeamDeathmatch::MultiplayerTeamDeathmatch(const TiXmlElement root)32 MultiplayerTeamDeathmatch::MultiplayerTeamDeathmatch(const TiXmlElement* root) 29 33 : GameRules(root) 30 {} 34 { 35 this->setClassID(CL_MULTIPLAYER_TEAM_DEATHMATCH, "MultiplayerTeamDeathmatch"); 36 37 if( root != NULL) 38 this->loadParams(root); 39 } 31 40 32 41 /** … … 39 48 40 49 void MultiplayerTeamDeathmatch::loadParams(const TiXmlElement* root) 50 { 51 GameRules::loadParams(root); 52 } 53 54 55 /** 56 * called when the player enters the game 57 * @param player the spawned player 58 */ 59 void MultiplayerTeamDeathmatch::onPlayerSpawn(Player* player) 41 60 {} 42 61 62 63 /** 64 * when the player is killed 65 * @param player the killed player 66 */ 67 void MultiplayerTeamDeathmatch::onPlayerDeath(Player* player) 68 {} 69 70 71 /** 72 * time tick 73 * @param dt time 74 */ 75 void MultiplayerTeamDeathmatch::tick(float dt) 76 {} 77 78 79 /** 80 * draws the stuff 81 */ 82 void MultiplayerTeamDeathmatch::draw() 83 {} 84 85 86 /** 87 * check the game rules for consistency 88 */ 89 void MultiplayerTeamDeathmatch::checkGameRules() 90 {} 91 92 93 94 95 96 -
trunk/src/util/multiplayer_team_deathmatch.h
r7034 r7035 1 1 2 2 /*! 3 * @file game_rules.h3 * @file multiplayer_team_deathmatch.h 4 4 * Defines game rules for this game 5 5 */ … … 20 20 21 21 public: 22 MultiplayerTeamDeathmatch(const TiXmlElement root);22 MultiplayerTeamDeathmatch(const TiXmlElement* root = NULL); 23 23 virtual ~MultiplayerTeamDeathmatch(); 24 24 … … 35 35 36 36 protected: 37 virtual void check MultiplayerTeamDeathmatch();37 virtual void checkGameRules(); 38 38 }; 39 39
Note: See TracChangeset
for help on using the changeset viewer.