Changeset 6485
- Timestamp:
- Mar 7, 2010, 11:16:03 PM (15 years ago)
- Location:
- code/branches/pickup3/src/orxonox/worldentities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/pickup3/src/orxonox/worldentities/WorldEntity.cc
r6417 r6485 201 201 registerVariable(this->parentID_, VariableDirection::ToClient, new NetworkCallback<WorldEntity>(this, &WorldEntity::networkcallback_parentChanged)); 202 202 } 203 204 /** 205 @brief 206 When the activity is changed, it is changed for all attached objects as well. 207 */ 208 void WorldEntity::changedActivity(void) 209 { 210 SUPER(WorldEntity, changedActivity); 211 212 for (std::set<WorldEntity*>::const_iterator it = this->getAttachedObjects().begin(); it != this->getAttachedObjects().end(); it++) 213 { 214 (*it)->setActive(this->isActive()); 215 } 216 } 217 218 /** 219 @brief 220 When the visibility is changed, it is changed for all attached objects as well. 221 */ 222 void WorldEntity::changedVisibility(void) 223 { 224 SUPER(WorldEntity, changedVisibility); 225 226 for (std::set<WorldEntity*>::const_iterator it = this->getAttachedObjects().begin(); it != this->getAttachedObjects().end(); it++) 227 { 228 (*it)->setVisible(this->isVisible()); 229 } 230 } 203 231 204 232 /** -
code/branches/pickup3/src/orxonox/worldentities/WorldEntity.h
r6417 r6485 106 106 static const Vector3 DOWN; 107 107 static const Vector3 UP; 108 109 virtual void changedActivity(void); 110 virtual void changedVisibility(void); 108 111 109 112 virtual void setPosition(const Vector3& position) = 0;
Note: See TracChangeset
for help on using the changeset viewer.