Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 5, 2018, 10:48:32 AM (6 years ago)
Author:
ottka
Message:

New HUDs and Start

Location:
code/branches/OrxoKart_HS18/src/modules/orxokart
Files:
2 added
6 edited

Legend:

Unmodified
Added
Removed
  • code/branches/OrxoKart_HS18/src/modules/orxokart/CMakeLists.txt

    r12108 r12144  
    55  OrxoKartOrigin.cc
    66  OrxoKartFlag.cc
     7  ShroomHUD.cc
    78  TimeHUD.cc
    89)
  • code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKart.cc

    r12128 r12144  
    5050        this->raceFinished = false;
    5151        this->firstTick_ = true;
     52        this->numberOfShrooms = 3;
    5253
    5354        this->setHUDTemplate("OrxoKartHUD");
     
    181182            OrxoKartKart* player = flag_->getObjectofCollision();
    182183            if (level == 1)
    183                 player->setPosition(Vector3(s*0, 20, s*8));
     184                player->setPosition(Vector3(s*0, 20, s*8.5));
    184185            if (level == 2)
    185                 player->setPosition(Vector3(s*0, 20, s*18));
     186                player->setPosition(Vector3(s*0, 20, s*18.5));
    186187            player->setOrientation(Quaternion(1, 0, 0, 0));   // 0, 0, 0
    187188            player->setVelocity(Vector3(0,0,0));
  • code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKart.h

    r12128 r12144  
    5757            inline int getRaceFinished() const
    5858                { return this->raceFinished; }
     59            inline int getNumberOfShrooms() const
     60                { return this->numberOfShrooms; }   
    5961
    6062        private:
     
    6870            bool firstTick_;
    6971
     72            int numberOfShrooms;
     73
    7074            int s;
    7175            int n;
  • code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKartPrereqs.h

    r12108 r12144  
    7474    class OrxoKartTile;
    7575    class TimeHUD;
     76    class ShroomHUD;
    7677}
    7778
  • code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKartTile.cc

    r12128 r12144  
    4848        this->model_ = nullptr;
    4949        this->cs_ = nullptr;
     50        this->arc = nullptr;
    5051
    5152        this->enableCollisionCallback();
     
    6667            if (this->cs_)
    6768                this->cs_->destroy();
     69            if (this->arc)
     70                this->arc->destroy();
    6871        }
    6972    }
     
    9093        else if (type == 2 ) {
    9194            model_->setMeshSource("OrxoKartStreckenabschnittZiel.mesh");
     95
     96            arc = new Model(this->getContext());
     97            arc->setMeshSource("OrxoKartStartTor.mesh");
     98            arc->setPosition(Vector3(x*1.0f, -1.0f, z*1.0f));
     99            arc->setScale3D(Vector3(s*1.0f/10, s*1.0f/10, s*1.0f/10));
     100            arc->yaw(Degree(-90));
     101            this->attach(arc);
    92102        }
    93103        model_->setScale3D(Vector3(s*1.0f, 8.0f, s*1.0f));
  • code/branches/OrxoKart_HS18/src/modules/orxokart/OrxoKartTile.h

    r12128 r12144  
    6565        private:
    6666            Model* model_;
     67            Model* arc;
    6768            BoxCollisionShape* cs_;
    6869            bool collided_;
Note: See TracChangeset for help on using the changeset viewer.