- Timestamp:
- May 12, 2016, 4:02:21 PM (9 years ago)
- Location:
- code/branches/tgidronFS16
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/tgidronFS16
- Property svn:mergeinfo changed
/code/trunk (added) merged: 11156-11157,11160-11161,11176
- Property svn:mergeinfo changed
-
code/branches/tgidronFS16/cmake/CompilerConfigClang.cmake
r11076 r11184 64 64 ADD_COMPILER_FLAGS("-Wno-deprecated" CXX CACHE) 65 65 66 # Triggers lots of warnings in boost headers67 ADD_COMPILER_FLAGS("-Wno-unused-local-typedefs" CXX CACHE)68 69 66 # Clang doesn't like some narrowing bullet does 70 67 ADD_COMPILER_FLAGS("-Wno-c++11-narrowing" CXX CACHE) -
code/branches/tgidronFS16/data/levels/Hover.oxw
r11182 r11184 20 20 <?lua 21 21 MAZE_NUM_CELLS = 10 22 MAZE_CELL_SIZE = 100 23 MAZE_CELL_HEIGHT = 30 22 MAZE_CELL_SIZE = 600 23 MAZE_CELL_HEIGHT = 180 24 MAZE_WALL_THICKNESS = 10 24 25 MAZE_SIZE = MAZE_NUM_CELLS*MAZE_CELL_SIZE 25 26 ?> … … 58 59 <StaticEntity> 59 60 <attached> 60 <Billboard position="0, 0,0" colour="1.0,0.55,1.0" material="Sphere2" scale=0.1>61 <Billboard position="0,50,0" colour="1.0,0.55,1.0" material="Sphere2" scale=1> 61 62 <attached> 62 63 <Billboard position="0,0,0" colour="1.0,0.55,1.0" material="Shrink" scale=0.35 /> … … 87 88 <StaticEntity> 88 89 <attached> 89 <Billboard position="0, 0,0" colour="0.99,0.96,0.52" material="Sphere2" scale=0.1>90 <Billboard position="0,50,0" colour="0.99,0.96,0.52" material="Sphere2" scale=1> 90 91 <attached> 91 92 <Billboard position="0,0,0" colour="0.98,0.94,0.22" material="3arrowsup" scale=0.7 /> … … 116 117 <StaticEntity> 117 118 <attached> 118 <Billboard position="0, 0,0" colour="0.6,0.⁰,0.8" material="Sphere2" scale=0.1>119 <Billboard position="0,50,0" colour="0.6,0.⁰,0.8" material="Sphere2" scale=1> 119 120 <attached> 120 121 <Billboard position="0,0,0" colour="0.6,0.⁰,0.8" material="Asterisk" scale=0.65 /> … … 136 137 <Pawn team=1 health=30 position="0,100,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box RVName = "Box 4" > 137 138 <attached> 138 <Model position="0, 0,0" mesh="crate.mesh" scale3D="3,3,3" />139 <Model position="0,50,0" mesh="crate.mesh" scale3D="15,15,15" /> 139 140 </attached> 140 141 <collisionShapes> 141 <BoxCollisionShape position="0,0,0" halfExtents=" 15,15,15" />142 <BoxCollisionShape position="0,0,0" halfExtents="70,70,70" /> 142 143 </collisionShapes> 143 144 </Pawn> … … 156 157 157 158 158 159 <?lua 160 for i = 1, 10, 1 do 161 for j = 1,10 ,1 do 162 ?> 163 164 <StaticEntity position="0,0,0" collisionType="static"> 165 <attached> 166 <Model 167 position="<?lua print(MAZE_CELL_SIZE*i)?>, -16, <?lua print(MAZE_CELL_SIZE*j)?>" 168 scale3D="<?lua print(MAZE_CELL_SIZE*i)?>, 16, <?lua print(MAZE_CELL_SIZE*j)?>" 169 mesh="CubeGround.mesh" 170 /> 171 </attached> 172 <collisionShapes> 173 <BoxCollisionShape 174 position="<?lua print(MAZE_CELL_SIZE*i)?>, <?lua print(MAZE_CELL_HEIGHT+1)?>, <?lua print(MAZE_CELL_SIZE*j)?>" 175 halfExtents="<?lua print(MAZE_CELL_SIZE*i)?>,1,<?lua print(MAZE_CELL_SIZE*j)?>" 176 /> 177 <BoxCollisionShape 178 position="<?lua print(MAZE_CELL_SIZE*i)?>,-1,<?lua print(MAZE_CELL_SIZE*j)?>" 179 halfExtents="<?lua print(MAZE_CELL_SIZE*i)?>,1,<?lua print(MAZE_CELL_SIZE*j)?>" 180 /> 181 </collisionShapes> 182 183 <?lua 184 end 185 end 186 ?> 187 188 </StaticEntity> 159 189 160 190 <Scene 161 191 ambientlight = "0.8, 0.8, 0.8" 162 192 skybox = "Orxonox/Starbox" 163 gravity = "0, - 200, 0"193 gravity = "0, -300, 0" 164 194 > 165 195 … … 210 240 pickuprepresentationtemplateshrink=smallshrinkpickupRepresentation 211 241 /> 212 <Model 213 position="<?lua print(MAZE_SIZE/2)?>,-16,<?lua print(MAZE_SIZE/2)?>" 214 scale3D="<?lua print(MAZE_SIZE/2)?>,16,<?lua print(MAZE_SIZE/2)?>" 215 mesh="CubeGround.mesh" 216 /> 217 </attached> 218 <collisionShapes> 219 <BoxCollisionShape 220 position="<?lua print(MAZE_SIZE/2)?>,<?lua print(MAZE_CELL_HEIGHT+1)?>,<?lua print(MAZE_SIZE/2)?>" 221 halfExtents="<?lua print(MAZE_SIZE/2)?>,1,<?lua print(MAZE_SIZE/2)?>" 222 /> 223 <BoxCollisionShape 224 position="<?lua print(MAZE_SIZE/2)?>,-1,<?lua print(MAZE_SIZE/2)?>" 225 halfExtents="<?lua print(MAZE_SIZE/2)?>,1,<?lua print(MAZE_SIZE/2)?>" 226 /> 227 </collisionShapes> 242 </attached> 243 228 244 </StaticEntity> 229 245 … … 238 254 <SpawnPoint 239 255 team=0 240 position=" 50,20,50"241 lookat=" 100,20,100"256 position="300,120,300" 257 lookat="600,120,600" 242 258 spawnclass=HoverShip 243 259 pawndesign=spaceshiphover … … 247 263 </Level> 248 264 265 266 267 <!--<<Model 268 position="<?lua print(MAZE_SIZE/2)?>,-16,<?lua print(MAZE_SIZE/2)?>" 269 scale3D="<?lua print(MAZE_SIZE/2)?>,16,<?lua print(MAZE_SIZE/2)?>" 270 mesh="ss_wall.mesh" 271 /> 272 </attached> 273 274 <collisionShapes> 275 <BoxCollisionShape 276 position="<?lua print(MAZE_SIZE/2)?>,<?lua print(MAZE_CELL_HEIGHT+1)?>,<?lua print(MAZE_SIZE/2)?>" 277 halfExtents="<?lua print(MAZE_SIZE/2)?>,1,<?lua print(MAZE_SIZE/2)?>" 278 /> 279 <BoxCollisionShape 280 position="<?lua print(MAZE_SIZE/2)?>,-1,<?lua print(MAZE_SIZE/2)?>" 281 halfExtents="<?lua print(MAZE_SIZE/2)?>,1,<?lua print(MAZE_SIZE/2)?>" 282 /> 283 </collisionShapes> --> -
code/branches/tgidronFS16/data/levels/emptyLevel.oxw
r11052 r11184 14 14 <?lua 15 15 include("templates/spaceshipEscort.oxt") 16 include("templates/spaceshipHover.oxt") 16 17 ?> 17 18 … … 29 30 <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0"/> 30 31 <SpawnPoint team=0 position="-200,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipescort /> 32 33 <SpaceShip position="0,0,0" lookat="0,0,0" > 34 35 <templates> 36 <Template link=spaceshiphover /> 37 </templates> 38 39 </SpaceShip> 31 40 32 41 </Scene> -
code/branches/tgidronFS16/data/levels/includes/weaponSettingsHover.oxi
r11177 r11184 1 1 <weaponslots> 2 <WeaponSlot position="- 3,2,-3" />3 <WeaponSlot position=" 3,2,-3" />2 <WeaponSlot position="-10,2,-100" /> 3 <WeaponSlot position=" 10,2,-100" /> 4 4 </weaponslots> 5 5 <weaponsets> -
code/branches/tgidronFS16/data/levels/templates/spaceshipHover.oxt
r11177 r11184 18 18 reloadwaittime = 0.5 19 19 20 primaryThrust = 200 20 primaryThrust = 2000 21 21 auxilaryThrust = 1 22 22 rotationThrust = 45 23 23 24 jumpBoost = 11024 jumpBoost = 230 25 25 26 26 lift = 1; 27 stallSpeed = 220;27 stallSpeed = 1400; 28 28 29 29 boostPower = 10 … … 33 33 34 34 collisionType = "dynamic" 35 mass = 1000 35 mass = 100000 36 36 linearDamping = 0.2 37 37 angularDamping = 0.9999999 … … 41 41 </engines> 42 42 <attached> 43 <Model position="0,0,- 20" mesh="hovership_body.mesh" scale="5" yaw=180/>44 <Model position="0,0,- 20" mesh="hovership_engine.mesh" scale="5" yaw=180/>45 <Model position="0,0,- 20" mesh="hovership_gun.mesh" scale="5" yaw=180/>43 <Model position="0,0,-120" mesh="hovership_body.mesh" scale="30" yaw=180/> 44 <Model position="0,0,-120" mesh="hovership_engine.mesh" scale="30" yaw=180/> 45 <Model position="0,0,-120" mesh="hovership_gun.mesh" scale="30" yaw=180/> 46 46 47 47 </attached> 48 48 <collisionShapes> 49 <BoxCollisionShape position="0,- 2 ,7" halfExtents="7, 4 ,30" />49 <BoxCollisionShape position="0,-12, 42" halfExtents="42, 24 ,180" /> 50 50 </collisionShapes> 51 51 <explosion> … … 69 69 <SpaceShip> 70 70 <camerapositions> 71 <CameraPosition position="0, 8, 5" drag=true mouselook=true />72 <CameraPosition position="0, 8,5" yaw="180" drag=true mouselook=true />71 <CameraPosition position="0, 48, 30" drag=true mouselook=true /> 72 <CameraPosition position="0, 48, 30" yaw="180" drag=true mouselook=true /> 73 73 </camerapositions> 74 74 </SpaceShip> … … 79 79 boostfactor = 2 80 80 81 speedfront = 1 5082 speedback = 4083 speedleftright = 4084 speedupdown = 4081 speedfront = 1400 82 speedback = 800 83 speedleftright = 600 84 speedupdown = 600 85 85 86 accelerationfront = 50087 accelerationbrake = 50086 accelerationfront = 1000 87 accelerationbrake = 1000 88 88 accelerationback = 250 89 accelerationleftright = 12589 accelerationleftright = 250 90 90 accelerationupdown = 125 91 91 > -
code/branches/tgidronFS16/src/libraries/core/command/TclThreadManager.cc
r11071 r11184 410 410 { 411 411 // This query would lead to a deadlock - return with an error 412 TclThreadManager::error("Circular query (" + this->dumpList(source_bundle->queriers_.getList()) + ' ' + multi_cast<std::string>(source_bundle->id_) \413 + " -> " + multi_cast<std::string>(target_bundle->id_) \414 + "), couldn't query Tcl-interpreter with ID " + multi_cast<std::string>(target_bundle->id_) \412 TclThreadManager::error("Circular query (" + this->dumpList(source_bundle->queriers_.getList()) + ' ' + multi_cast<std::string>(source_bundle->id_) 413 + " -> " + multi_cast<std::string>(target_bundle->id_) 414 + "), couldn't query Tcl-interpreter with ID " + multi_cast<std::string>(target_bundle->id_) 415 415 + " from other interpreter with ID " + multi_cast<std::string>(source_bundle->id_) + '.'); 416 416 } -
code/branches/tgidronFS16/src/modules/hover/Hover.cc
r11182 r11184 169 169 Pawn* crate = new Pawn(origin_->getContext()); 170 170 171 172 crate->addTemplate(origin_->getObstacleTemplate()); 171 173 crate->setPosition(get3dCoordinates(rand()%numCells, rand()%numCells, 10.0f)); 172 crate->addTemplate(origin_->getObstacleTemplate()); 173 crate->setInitialHealth(100.0f); 174 //ate->setInitialHealth(100.0f); 174 175 175 176 -
code/branches/tgidronFS16/src/modules/hover/HoverFlag.cc
r11099 r11184 87 87 model_ = new Model(this->getContext()); 88 88 model_->setMeshSource("ss_flag_eu.mesh"); 89 model_->setScale3D(Vector3( 5, 5, 5));90 model_->setPosition(Vector3(xCoordinate*cellSize*1.0f + cellSize/2, 10.0f,yCoordinate*cellSize*1.0f + cellSize/2));89 model_->setScale3D(Vector3(30, 30, 30)); 90 model_->setPosition(Vector3(xCoordinate*cellSize*1.0f + cellSize/2,50.0f,yCoordinate*cellSize*1.0f + cellSize/2)); 91 91 92 92 this->attach(model_); 93 93 94 94 cs_ = new BoxCollisionShape(this->getContext()); 95 cs_->setHalfExtents(Vector3( 5, 5, 5));95 cs_->setHalfExtents(Vector3(30, 30, 30)); 96 96 cs_->setPosition(Vector3(xCoordinate*cellSize*1.0f + cellSize/2,0.0f,yCoordinate*cellSize*1.0f + cellSize/2)); 97 97 -
code/branches/tgidronFS16/src/modules/hover/HoverOrigin.cc
r11182 r11184 48 48 //not needed 49 49 50 /*pickupTemplate_ = "";50 pickupTemplate_ = ""; 51 51 pickupRepresentationTemplate_ = ""; 52 52 … … 56 56 57 57 pickupTemplateShrink_ = ""; 58 pickupRepresentationTemplateShrink_ = ""; */58 pickupRepresentationTemplateShrink_ = ""; 59 59 } 60 60 -
code/branches/tgidronFS16/src/orxonox/Scene.h
r11085 r11184 48 48 #include "network/synchronisable/Synchronisable.h" 49 49 #include "tools/interfaces/Tickable.h" 50 #include "core/command/ConsoleCommandIncludes.h" 50 51 51 52 namespace orxonox -
code/branches/tgidronFS16/src/orxonox/gametypes/TeamGametype.cc
r11071 r11184 141 141 void TeamGametype::spawnDeadPlayersIfRequested() 142 142 { 143 for (const auto& mapEntry : this->players_) \143 for (const auto& mapEntry : this->players_) 144 144 { 145 145 if(allowedInGame_[mapEntry.first] == false)//check if dead player is allowed to enter -
code/branches/tgidronFS16/src/orxonox/weaponsystem/WeaponSystem.h
r11071 r11184 55 55 void removeWeaponSlot(WeaponSlot * wSlot); 56 56 WeaponSlot * getWeaponSlot(unsigned int index) const; 57 inline const std::vector<WeaponSlot *>& getAllWeaponSlots() const 58 { return weaponSlots_; } 57 59 58 60 // adding and removing WeaponSets -
code/branches/tgidronFS16/src/orxonox/worldentities/pawns/Pawn.cc
r11099 r11184 49 49 #include "weaponsystem/Munition.h" 50 50 #include "sound/WorldSound.h" 51 #include "core/object/ObjectListIterator.h" 51 52 52 53 #include "controllers/FormationController.h" … … 55 56 { 56 57 RegisterClass(Pawn); 58 59 SetConsoleCommand("Pawn", "debugDrawWeapons", &Pawn::consoleCommand_debugDrawWeapons).addShortcut(); 57 60 58 61 Pawn::Pawn(Context* context) … … 168 171 { 169 172 registerVariable(this->bAlive_, VariableDirection::ToClient); 173 registerVariable(this->bVulnerable_, VariableDirection::ToClient); 170 174 registerVariable(this->health_, VariableDirection::ToClient); 171 175 registerVariable(this->maxHealth_, VariableDirection::ToClient); … … 592 596 return BLANKSTRING; 593 597 } 598 599 void Pawn::drawWeapons(bool bDraw) 600 { 601 if (bDraw) 602 { 603 std::vector<WeaponSlot*> weaponSlots = weaponSystem_->getAllWeaponSlots(); 604 int numWeaponSlots = weaponSlots.size(); 605 Vector3 slotPosition = Vector3::ZERO; 606 Quaternion slotOrientation = Quaternion::IDENTITY; 607 Model* slotModel = nullptr; 608 609 for (int i = 0; i < numWeaponSlots; ++i) 610 { 611 slotPosition = weaponSlots.at(i)->getPosition(); 612 slotOrientation = weaponSlots.at(i)->getOrientation(); 613 slotModel = new Model(this->getContext()); 614 slotModel->setMeshSource("Coordinates.mesh"); 615 slotModel->setScale(3.0f); 616 slotModel->setOrientation(slotOrientation); 617 slotModel->setPosition(slotPosition); 618 619 this->attach(slotModel); 620 debugWeaponSlotModels_.push_back(slotModel); 621 } 622 } 623 else 624 { 625 // delete all debug models 626 for(Model* model : debugWeaponSlotModels_) 627 { 628 model->destroy(); 629 } 630 debugWeaponSlotModels_.clear(); 631 } 632 } 633 634 /*static*/ void Pawn::consoleCommand_debugDrawWeapons(bool bDraw) 635 { 636 if (bDraw) 637 { 638 orxout() << "WeaponSlot visualization enabled." << endl; 639 } 640 else 641 { 642 orxout() << "WeaponSlot visualization disabled." << endl; 643 } 644 645 ObjectList<Pawn> pawnList; 646 for (ObjectListIterator<Pawn> it = pawnList.begin(); it != pawnList.end(); ++it) 647 { 648 it->drawWeapons(bDraw); 649 } 650 } 594 651 } -
code/branches/tgidronFS16/src/orxonox/worldentities/pawns/Pawn.h
r11071 r11184 218 218 { return this->weaponSystem_; } 219 219 220 static void consoleCommand_debugDrawWeapons(bool bDraw); 221 220 222 protected: 221 223 virtual void preDestroy() override; … … 233 235 234 236 bool bAlive_; 235 bool bVulnerable_; ///< If false the pawn may not ged damaged237 bool bVulnerable_; ///< If this is false, then the pawn may not take damage 236 238 237 239 virtual std::vector<PickupCarrier*>* getCarrierChildren(void) const override … … 269 271 inline void setWeaponSystem(WeaponSystem* weaponsystem) 270 272 { this->weaponSystem_ = weaponsystem; } 273 void drawWeapons(bool bDraw); 271 274 272 275 Vector3 aimPosition_; 273 276 274 277 WorldSound* explosionSound_; // TODO: Does this really belong here? Maybe move it to BigExplosion? 278 279 std::vector<Model*> debugWeaponSlotModels_; 275 280 276 281 }; // tolua_export -
code/branches/tgidronFS16/test/util/StringUtilsTest.cc
r9114 r11184 267 267 EXPECT_EQ(0, nocaseCmp("TesT", "teST")); 268 268 269 EXPECT_EQ(strcmp("a", "b") , nocaseCmp("a", "b"));270 EXPECT_EQ(strcmp("b", "a") , nocaseCmp("b", "a"));271 EXPECT_EQ(strcmp("hello", "world") , nocaseCmp("hello", "world"));269 EXPECT_EQ(strcmp("a", "b") < 0, nocaseCmp("a", "b") < 0); 270 EXPECT_EQ(strcmp("b", "a") > 0, nocaseCmp("b", "a") > 0); 271 EXPECT_EQ(strcmp("hello", "world") < 0, nocaseCmp("hello", "world") < 0); 272 272 } 273 273
Note: See TracChangeset
for help on using the changeset viewer.