Changeset 12156 for code/branches/OrxoKart_HS18/src
- Timestamp:
- Dec 5, 2018, 12:34:31 PM (6 years ago)
- Location:
- code/branches/OrxoKart_HS18/src/modules/orxokart
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKart.cc
r12155 r12156 51 51 this->firstTick_ = true; 52 52 this->numberOfShrooms = 3; 53 this->player = nullptr; 53 54 54 55 this->setHUDTemplate("OrxoKartHUD"); … … 105 106 0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,2,1,1,1,0,1,1,1}; 106 107 107 108 109 108 int *levelcodeArray = level==1 ? map_1 : map_2; 110 111 112 113 //OrxoKartTile* tile = new OrxoKartTile(origin_->getContext());114 //tile->init(0*s, 4*s, s, 20, 2);115 116 117 109 // int z = 0; 118 110 //Generate floor according to levelcode … … 176 168 177 169 170 orxout() << numberOfShrooms << endl; 178 171 179 172 180 // Check if ship collided with the flag 173 // Check if ship collided with the flag, flag is the bottom that is responsible for the game to detect the spaceship falling. 181 174 if(flag_->getCollided()){ 175 orxout() << numberOfShrooms << endl; 182 176 player = flag_->getObjectofCollision(); 183 177 if (level == 1) … … 190 184 flag_->setCollided(false); 191 185 wayPointCounter = 0; 186 } 192 187 188 if (player && player->isBoosting()) { 189 orxout() << "Boosting" << endl; 190 if(!numberOfShrooms) numberOfShrooms--; 193 191 } 194 192 -
code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKartFlag.cc
r12108 r12156 86 86 void OrxoKartFlag::init(int n, int s) 87 87 { 88 /*model_ = new Model(this->getContext());89 model_->setMeshSource("OrxoKart Streckenabschnitt.mesh");90 model_->setScale3D(Vector3(s *n*2, 1, s*n*2));91 model_->setPosition(Vector3(s*n*0.5f,- 60.0f, s*n*0.5f));88 model_ = new Model(this->getContext()); 89 model_->setMeshSource("OrxoKartMushroom.mesh"); 90 model_->setScale3D(Vector3(s, s, s)); 91 model_->setPosition(Vector3(s*n*0.5f,-0.0f, s*n*0.5f)); 92 92 93 this->attach(model_); */93 this->attach(model_); 94 94 95 95 cs_ = new BoxCollisionShape(this->getContext()); … … 98 98 99 99 this->attachCollisionShape(cs_); 100 101 100 102 } 101 103
Note: See TracChangeset
for help on using the changeset viewer.