Changeset 10834 for code/branches/campaignHS15
- Timestamp:
- Nov 23, 2015, 1:24:51 PM (9 years ago)
- Location:
- code/branches/campaignHS15
- Files:
-
- 9 edited
- 13 copied
Legend:
- Unmodified
- Added
- Removed
-
code/branches/campaignHS15
-
code/branches/campaignHS15/src/libraries/util/Math.cc
r10630 r10834 161 161 - If the other object is exactly above me, the function returns <tt>Vector2(0, 0.5)</tt>. 162 162 */ 163 orxonox::Vector2 get2DView coordinates(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition)163 orxonox::Vector2 get2DViewCoordinates(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition) 164 164 { 165 165 orxonox::Vector3 distance = otherposition - myposition; -
code/branches/campaignHS15/src/libraries/util/Math.h
r9939 r10834 91 91 _UtilExport float getAngle(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& otherposition); 92 92 _UtilExport orxonox::Vector2 get2DViewdirection(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition); 93 _UtilExport orxonox::Vector2 get2DView coordinates(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition);93 _UtilExport orxonox::Vector2 get2DViewCoordinates(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition); 94 94 _UtilExport orxonox::Vector2 get3DProjection(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition, const float mapangle, const float detectionlimit); 95 95 _UtilExport bool isObjectHigherThanShipOnMap(const orxonox::Vector3& myposition, const orxonox::Vector3& mydirection, const orxonox::Vector3& myorthonormal, const orxonox::Vector3& otherposition, const float mapangle); -
code/branches/campaignHS15/src/modules/docking/DockingController.cc
r9667 r10834 61 61 62 62 float distance = (this->dock_->getWorldPosition() - entity->getPosition()).length(); 63 Vector2 coord = get2DView coordinates( // I don't understand this too63 Vector2 coord = get2DViewCoordinates( // I don't understand this too 64 64 entity->getPosition(), 65 65 entity->getOrientation() * WorldEntity::FRONT, -
code/branches/campaignHS15/src/modules/overlays/hud/HUDRadar.cc
r9945 r10834 240 240 } 241 241 else 242 coord = get2DView coordinates(this->owner_->getPosition(), this->owner_->getOrientation() * WorldEntity::FRONT, this->owner_->getOrientation() * WorldEntity::UP, wePointer->getWorldPosition());242 coord = get2DViewCoordinates(this->owner_->getPosition(), this->owner_->getOrientation() * WorldEntity::FRONT, this->owner_->getOrientation() * WorldEntity::UP, wePointer->getWorldPosition()); 243 243 244 244 coord *= math::pi / 3.5f; // small adjustment to make it fit the texture -
code/branches/campaignHS15/src/orxonox/controllers/CMakeLists.txt
r10216 r10834 11 11 FormationController.cc 12 12 ControllerDirector.cc 13 DivisionController.cc 14 LeaderController.cc 15 WingmanController.cc 16 SectionController.cc 17 CommonController.cc 13 18 ) -
code/branches/campaignHS15/src/orxonox/controllers/FormationController.cc
r10631 r10834 277 277 } 278 278 279 Vector2 coord = get2DView coordinates(this->getControllableEntity()->getPosition(), this->getControllableEntity()->getOrientation() * WorldEntity::FRONT, this->getControllableEntity()->getOrientation() * WorldEntity::UP, target);279 Vector2 coord = get2DViewCoordinates(this->getControllableEntity()->getPosition(), this->getControllableEntity()->getOrientation() * WorldEntity::FRONT, this->getControllableEntity()->getOrientation() * WorldEntity::UP, target); 280 280 float distance = (target - this->getControllableEntity()->getPosition()).length(); 281 281 float rotateX = clamp(coord.x * 10, -1.0f, 1.0f); … … 1069 1069 return; 1070 1070 1071 Vector2 coord = get2DView coordinates(this->getControllableEntity()->getPosition(), this->getControllableEntity()->getOrientation() * WorldEntity::FRONT, this->getControllableEntity()->getOrientation() * WorldEntity::UP, target);1071 Vector2 coord = get2DViewCoordinates(this->getControllableEntity()->getPosition(), this->getControllableEntity()->getOrientation() * WorldEntity::FRONT, this->getControllableEntity()->getOrientation() * WorldEntity::UP, target); 1072 1072 float distance = (target - this->getControllableEntity()->getPosition()).length(); 1073 1073 -
code/branches/campaignHS15/src/orxonox/worldentities/pawns/Pawn.cc
r10624 r10834 299 299 } 300 300 301 302 301 void Pawn::kill() 303 302 { … … 319 318 } 320 319 } 321 322 320 323 321 void Pawn::death() … … 472 470 } 473 471 472 /** 473 @brief 474 Check whether the Pawn has a @ref Orxonox::WeaponSystem and fire it with the specified firemode if it has one. 475 */ 474 476 void Pawn::fired(unsigned int firemode) 475 477 { -
code/branches/campaignHS15/test/util/MathTest.cc
r9114 r10834 337 337 getAngle 338 338 get2DViewdirection 339 get2DView coordinates339 get2DViewCoordinates 340 340 getPredictedPosition 341 341 */
Note: See TracChangeset
for help on using the changeset viewer.