Changeset 12380
- Timestamp:
- May 16, 2019, 3:10:44 PM (6 years ago)
- Location:
- code/branches/3DPacman_FS19
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/3DPacman_FS19/data/levels/3DPacman.oxw
r12375 r12380 88 88 <!-- POINTS first Line --> 89 89 90 <PacmanLaser position=" -215,10,245">91 <attached> 92 <Model position="0, 60,-40" yaw="90" pitch="-90" roll="0" scale3D="1, 1, 10" mesh="LaserBeam2.mesh" />90 <PacmanLaser position="20,-200,150"> 91 <attached> 92 <Model position="0, 0, 0" yaw="90" pitch="-90" roll="0" scale3D="1, 1, 10" mesh="LaserBeam2.mesh" /> 93 93 </attached> 94 94 </PacmanLaser> -
code/branches/3DPacman_FS19/src/modules/pacman/CMakeLists.txt
r12320 r12380 11 11 PacmanBrown.cc 12 12 PacmanCyan.cc 13 PacmanLaser.cpp 13 14 ) 14 15 -
code/branches/3DPacman_FS19/src/modules/pacman/Pacman.cc
r12365 r12380 88 88 dead(dt); 89 89 90 if(point > 230){ 90 91 92 } 93 94 //ingame loop 95 else{ 96 if(point > 5){ 91 97 92 98 for(PacmanPointSphere* pointer : ObjectList<PacmanPointSphere>()){ 93 pointSpherePosition = pointer->getPosition();99 Vector3 pointSpherePosition = pointer->getPosition(); 94 100 95 101 if(pointSpherePosition.y > 0){ 96 PacmanLaser* pos = ObjectList<PacmanLaser>(); //to do 102 103 PacmanLaser* pos = *(ObjectList<PacmanLaser>().begin()); 97 104 pos->setPosition(pointSpherePosition); 105 orxout()<<"hellooooo" <<endl; 98 106 break; 99 107 } … … 103 111 104 112 } 105 106 }107 108 //ingame loop109 else{110 113 111 114 //Register ghosts … … 223 226 void Pacman::takePoint(PacmanPointSphere* taken){ 224 227 ++point; 225 }228 226 229 if(point == totallevelpoint){ 227 230 this->levelUp(); -
code/branches/3DPacman_FS19/src/modules/pacman/PacmanLaser.cpp
r12365 r12380 16 16 PacmanLaser::PacmanLaser(Context* context) : ControllableEntity(context) 17 17 { 18 RegisterObject(Pacman PointSphere);18 RegisterObject(PacmanLaser); 19 19 this->setCollisionType(CollisionType::None); 20 20 } … … 33 33 Method for creating a AutonomousDrone through XML. 34 34 */ 35 void Pacman PointSphere::XMLPort(Element& xmlelement, XMLPort::Mode mode)35 void PacmanLaser::XMLPort(Element& xmlelement, XMLPort::Mode mode) 36 36 { 37 SUPER(Pacman PointSphere, XMLPort, xmlelement, mode);37 SUPER(PacmanLaser, XMLPort, xmlelement, mode); 38 38 } 39 39 … … 41 41 void PacmanLaser::tick(float dt) 42 42 { 43 SUPER(Pacman PointSphere, tick, dt);43 SUPER(PacmanLaser, tick, dt); 44 44 } 45 45 -
code/branches/3DPacman_FS19/src/modules/pacman/PacmanLaser.h
r12365 r12380 18 18 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); //!< Method for creating an AutonomousDrone through XML. 19 19 virtual void tick(float dt); //!< Defines which actions the AutonomousDrone has to take in each tick. 20 20 21 void resetPacmanLaser(); 21 22 22 23 -
code/branches/3DPacman_FS19/src/modules/pacman/PacmanPointSphere.cc
r12365 r12380 82 82 return false; 83 83 } 84 bool showLaserPointSphere = false;85 86 87 88 89 84 //Reset position 90 85 void PacmanPointSphere::resetPacmanPointSphere(){
Note: See TracChangeset
for help on using the changeset viewer.