Changeset 4975 in orxonox.OLD for orxonox/trunk/src/world_entities/player.cc
- Timestamp:
- Aug 9, 2005, 12:23:07 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world_entities/player.cc
r4969 r4975 56 56 } 57 57 58 59 /** 60 * destructs the player, deletes alocated memory 61 */ 62 Player::~Player () 63 { 64 /* do not delete the weapons, they are contained in the pnode tree 65 and will be deleted there. 66 this only frees the memory allocated to save the list. 67 */ 68 delete this->weaponMan; 58 /** 59 * loads a Players information from a specified file. 60 * @param fileName the name of the File to load the player from (absolute path) 61 */ 62 Player::Player(const char* fileName) 63 { 64 this->init(); 65 TiXmlDocument doc(fileName); 66 67 if(!doc.LoadFile()) 68 { 69 PRINTF(2)("Loading file %s failed for player.\n", fileName); 70 return; 71 } 72 73 this->loadParams(doc.RootElement()); 69 74 } 70 75 … … 96 101 97 102 this->weaponMan->changeWeaponConfig(0); 103 } 104 105 /** 106 * destructs the player, deletes alocated memory 107 */ 108 Player::~Player () 109 { 110 /* do not delete the weapons, they are contained in the pnode tree 111 and will be deleted there. 112 this only frees the memory allocated to save the list. 113 */ 114 delete this->weaponMan; 98 115 } 99 116
Note: See TracChangeset
for help on using the changeset viewer.