Changeset 8856 in orxonox.OLD for branches/multi_player_map
- Timestamp:
- Jun 28, 2006, 2:43:05 PM (18 years ago)
- Location:
- branches/multi_player_map/src/util
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/multi_player_map/src/util/game_rules.cc
r8840 r8856 92 92 93 93 PRINTF(0)("Received Event: Kill\n"); 94 // this->killList.push_back(kill); 94 95 this->killList.push_back( kill ); 95 96 } 96 97 -
branches/multi_player_map/src/util/game_rules.h
r8802 r8856 9 9 10 10 #include "base_object.h" 11 #include <list> 11 12 #include <vector> 12 13 … … 54 55 std::vector<MissionGoal*> missionList; //!< list of mission goals 55 56 56 std:: vector<Kill>killList; //!< list of kills in the world57 std::list<Kill> killList; //!< list of kills in the world 57 58 }; 58 59 -
branches/multi_player_map/src/util/multiplayer_team_deathmatch.cc
r8851 r8856 68 68 this->numTeams = 2; 69 69 this->currentGameState = GAMESTATE_PRE_GAME; 70 this->gameStateTimer = 10.0f;70 this->gameStateTimer = 3.0f; 71 71 this->bShowTeamChange = false; 72 72 … … 221 221 222 222 //handle kills 223 for ( std::vector<Kill>::iterator it = this->killList.begin(); it != this->killList.end(); ) 224 { 225 std::vector<Kill>::iterator delit = it; 226 227 onKill( it->getKiller()->getOwner(), it->getVictim()->getOwner() ); 228 229 it++; 230 killList.erase( delit ); 231 } 223 while ( this->killList.begin() != this->killList.end() ) 224 { 225 if ( this->killList.begin()->getKiller() != NULL && this->killList.begin()->getVictim() != NULL ) 226 onKill( this->killList.begin()->getKiller()->getOwner(), this->killList.begin()->getVictim()->getOwner() ); 227 this->killList.erase( this->killList.begin() ); 228 } 229 230 232 231 233 232 gameStateTimer -= dt;
Note: See TracChangeset
for help on using the changeset viewer.