Changeset 11931
- Timestamp:
- May 3, 2018, 2:57:35 PM (7 years ago)
- Location:
- code/branches/3DPacman_FS18
- Files:
-
- 3 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/3DPacman_FS18/data/levels/3DPacman.oxw
r11918 r11931 34 34 <SpawnPoint team=0 position="0,10,245" lookat="0,0,0" spawnclass=PacmanGelb pawndesign=PacmanGelb /> 35 35 36 37 <--! GHOSTS --> 38 <PacmanGhost position="0,0,0"> 36 <!-- GHOSTS --> 37 <PacmanGhost position="0,10,15" > 39 38 <attached> 40 39 <Model position="0,0,0" mesh="PacmanGhostRed.mesh" scale="5" /> … … 42 41 </PacmanGhost> 43 42 44 <PacmanGhost position="0, 0,0">43 <PacmanGhost position="0,10,15" > 45 44 <attached> 46 45 <Model position="0,0,0" mesh="PacmanGhostBlue.mesh" scale="5" /> … … 48 47 </PacmanGhost> 49 48 50 <PacmanGhost position="0, 0,0">49 <PacmanGhost position="0,10,15" > 51 50 <attached> 52 51 <Model position="0,0,0" mesh="PacmanGhostOrange.mesh" scale="5" /> … … 54 53 </PacmanGhost> 55 54 56 <PacmanGhost position="0, 0,0">55 <PacmanGhost position="0,10,15" > 57 56 <attached> 58 57 <Model position="0,0,0" mesh="PacmanGhostPink.mesh" scale="5" /> … … 60 59 </PacmanGhost> 61 60 62 < --!POINTS -->61 <!-- POINTS --> 63 62 <PacmanPointSphere position="0,10,0"> 64 63 <attached> … … 80 79 81 80 82 83 84 <--! Map --> 81 <!-- Map --> 85 82 <StaticEntity position="0,0,25" direction="0,0,0" collisionType=static mass=100000 friction=0.01 > 86 83 <attached> … … 89 86 <collisionShapes> 90 87 91 < --! Edge -->92 93 88 <!-- Edge --> 89 <BoxCollisionShape position="250,10,0" halfExtents="1,15,250" /> 90 <BoxCollisionShape position="-250,10,0" halfExtents="1,15,250" /> 94 91 <BoxCollisionShape position="0,10,250" halfExtents="250,15,1" /> 95 92 <BoxCollisionShape position="0,10,-250" halfExtents="250,15,1" /> 96 93 97 <--! Shapes in order --> 98 <BoxCollisionShape position="-35,10,-200" halfExtents="40,15,25" /> 99 <BoxCollisionShape position="60,10,-200" halfExtents="40,15,25" /> 100 <BoxCollisionShape position="-35,10,200" halfExtents="40,15,25" /> 101 <BoxCollisionShape position="60,10,200" halfExtents="40,15,25" /> 102 103 <BoxCollisionShape position="-175,10,-165" halfExtents="30,15,20" /> 104 105 94 <!-- Shapes in order --> 95 <BoxCollisionShape position="-200,10,-65" halfExtents="55,15,35" /> 96 <BoxCollisionShape position="-200,10,30" halfExtents="55,15,35" /> 97 <BoxCollisionShape position="200,10,-65" halfExtents="55,15,35" /> 98 <BoxCollisionShape position="200,10,30" halfExtents="55,15,35" /> 106 99 107 100 </collisionShapes> … … 112 105 <PortalLink fromID="1" toID="2" /> 113 106 <PortalLink fromID="2" toID="1" /> 114 115 107 </Scene> 116 108 </Level> -
code/branches/3DPacman_FS18/data/levels/templates/PacmanGelb.oxt
r11900 r11931 50 50 </attached> 51 51 <collisionShapes> 52 <BoxCollisionShape position="0 ,0 , 3" halfExtents="10, 4,8" /> 53 <BoxCollisionShape position="12.6 ,-2, 3" halfExtents="2.8,2.8,11"/> 54 <BoxCollisionShape position="-12.6,-2, 3" halfExtents="2.8,2.8,11"/> 55 <BoxCollisionShape position="0, 0,-12" halfExtents="4 , 4 ,7" /> 52 <BoxCollisionShape position="0 ,0 , 0" halfExtents="1,1,1" /> 56 53 </collisionShapes> 57 54 … … 74 71 boostfactor = 1.0 75 72 76 speedfront = 5073 speedfront = 60 77 74 speedback = 20 78 75 speedleftright = 1 -
code/branches/3DPacman_FS18/src/modules/pacman/Pacman.cc
r11915 r11931 44 44 RegisterObject(Pacman); 45 45 46 // firstGame = true; //needed for the HUD 46 47 lives = 10; 47 48 point = 0; 48 49 level = 1; 49 50 51 // setHUDTemplate("PacmanOrxHUD"); 52 // scoreboardTemplate_ = ""; 50 53 } 51 54 … … 97 100 98 101 bool Pacman::collis(Vector3 one, Vector3 other){ 99 if((abs(one.x-other.x)< 7) && (abs(one.y-other.y)<7) && (abs(one.z-other.z)<7))102 if((abs(one.x-other.x)<10) && (abs(one.y-other.y)<10) && (abs(one.z-other.z)<10)) 100 103 return true; 101 104 return false; … … 146 149 void Pacman::end() 147 150 { 151 /* 152 firstGame = false; 153 154 //Set randomized deathmessages 155 if(point<7) sDeathMessage = DeathMessage7[rand()%(DeathMessage7.size())]; 156 else if(point<20) sDeathMessage = DeathMessage20[rand()%(DeathMessage20.size())]; 157 else if(point<30) sDeathMessage = DeathMessage30[rand()%(DeathMessage30.size())]; 158 else sDeathMessage = DeathMessageover30[rand()%(DeathMessageover30.size())]; 159 160 //Update Highscore 161 if (Highscore::exists()) 162 { 163 int score = this->getPoints(); 164 Highscore::getInstance().storeScore("Pacman", score, this->getPlayer()->getPlayer()); 165 } 166 167 148 168 if (Highscore::exists()) 149 169 { … … 151 171 //Highscore::getInstance().storeScore("3DPacman", score, this->playerInfo_); 152 172 } 173 */ 153 174 GSLevel::startMainMenu(); 154 175 } -
code/branches/3DPacman_FS18/src/modules/pacman/Pacman.h
r11915 r11931 94 94 Vector3 startposplayer = Vector3(0,10,245); 95 95 int totallevelpoint = 3; 96 //bool firstGame; 96 97 97 98 private: … … 107 108 Timer showLevelTimer; 108 109 109 110 /* 111 112 //void spawnEnemy(); 113 114 115 116 117 118 119 120 121 122 123 124 125 private: 126 127 128 129 130 //Context* context; 131 */ 110 /* 111 std::string sDeathMessage; 112 const std::vector<std::string> DeathMessage7 = { 113 "You should really try that again", 114 "You can do better, can you?", 115 "Hey, maybe you get a participation award, that's good isn't it?", 116 "Congratulations, you get a medal, a wooden one", 117 "That was flappin bad!", 118 "Well, that was a waste of time", 119 "You suck!", 120 "Maybe try SuperOrxoBros. That game is not as hard.", 121 "Here's a tip: Try not to fly into these grey thingies.", 122 "We won't comment on that."}; 123 const std::vector<std::string> DeathMessage20 = { 124 "Getting better!", 125 "Training has paid off, huh?", 126 "Good average!", 127 "That was somehow enjoyable to watch", 128 "Flappin average", 129 "Getting closer to something", 130 "That wasn't crap, not bad", 131 "Surprisingly not bad."}; 132 */ 133 132 134 }; 133 135 } 134 136 135 #endif /* _ DodgeRace_H__ */137 #endif /* _Pacman_H__ */ -
code/branches/3DPacman_FS18/src/modules/pacman/PacmanGhost.cc
r11927 r11931 49 49 50 50 this->setCollisionType(CollisionType::Dynamic); 51 52 this->resetposition = this->getPosition(); //Set Default start position53 51 54 52 this->actuelposition = this->getPosition(); … … 325 323 setnewTarget(56,64); 326 324 } 325 else if(findpos(actuelposition,possibleposition[66])){ 326 setnewTarget(47,48); 327 } 327 328 328 329 else{ -
code/branches/3DPacman_FS18/src/modules/pacman/PacmanGhost.h
r11920 r11931 67 67 Vector3 actuelposition; 68 68 Vector3 velocity; 69 Vector3 resetposition ;69 Vector3 resetposition = Vector3(0,10,15); 70 70 }; 71 71
Note: See TracChangeset
for help on using the changeset viewer.