Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 14, 2011, 2:16:45 PM (13 years ago)
Author:
eceline
Message:

not much changed

Location:
code/branches/spaceraceTwo/src/modules/gametypes
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • code/branches/spaceraceTwo/src/modules/gametypes/RaceCheckPoint.cc

    r8970 r8979  
    5959        this->settingsChanged();
    6060        this->reached_=NULL;
    61         //this->addTarget("WorldEntity");
     61     
    6262    }
    6363   
  • code/branches/spaceraceTwo/src/modules/gametypes/RaceCheckPoint.h

    r8970 r8979  
    4242    @brief
    4343        The RaceCheckPoint class enables the creation of a check point to use in a SpaceRace level.
    44         !!! Don't forget to control the indexes of your check points and to set one last check point!!!
     44         Don't forget to control the indexes of your check points and to set one last check point
    4545    */
    4646    class _GametypesExport RaceCheckPoint : public DistanceMultiTrigger, public RadarViewable
     
    8383
    8484        private:
    85             int bCheckpointIndex_; //The index of this check point. This value will be compared with the number of check points reached in the level. The check points must be indexed in ascending order beginning from zero and without any jumps between the indexes.
     85            int bCheckpointIndex_; //The index of this check point.
     86            Vector3 nextcheckpoints_; //the indexes of the next check points
    8687           
    87             Vector3 nextcheckpoints_; //the indexes of the next check points
    88             std::vector<RaceCheckPoint*> next_;
    8988    };
    9089}
  • code/branches/spaceraceTwo/src/modules/gametypes/SpaceRace.cc

    r8971 r8979  
    5151        this->cantMove_=false;
    5252       
    53        for (std::map<PlayerInfo*, Player>::iterator it = this->players_.begin(); it != this->players_.end(); ++it)
    54         {this->checkpointReached_[it->first]=-1;} //TODO: should be removed; no functionallity
    55        
    5653    }
     54       
    5755   
    5856  // void SpaceRace::SetConfigValues(){
     
    8381            const_cast<GametypeInfo*>(this->getGametypeInfo())->sendAnnounceMessage(message);
    8482            ChatManager::message(message);
    85 /*
     83
    8684            float time = this->clock_.getSecondsPrecise();
    8785            this->scores_.insert(time);
    8886            std::set<float>::iterator it;
    89             for (it=this->scores_.begin(); it!=this->scores_.end(); it++)
    90                 orxout(level::message) << multi_cast<std::string>(*it) << endl;
    91 */
     87           
     88
    9289        }
    9390    }
     
    9996        Gametype::checkStart();
    10097        this->cantMove_=true;
    101         //TODO: switch the engine off/on via a short function 
     98       
    10299        for(ObjectList<Engine>::iterator it = ObjectList<Engine>::begin(); it; ++it)
    103100        {
    104101            it->setActive(false);
    105             /*if(it->getMaxSpeedFront()>0)
    106             {
    107                 this->maxSpeedBack_=it->getMaxSpeedBack();
    108                 this->maxSpeedFront_=it->getMaxSpeedFront();
    109                 this->maxSpeedLeftRight_=it->getMaxSpeedLeftRight();
    110                 this->maxSpeedUpDown_=(it->getMaxSpeedUpDown());
    111             }
    112             it->setMaxSpeedBack(0);
    113             it->setMaxSpeedFront(0);
    114             it->setMaxSpeedLeftRight(0);
    115             it->setMaxSpeedUpDown(0);*/
     102           
    116103        }
    117104        this->addBots(this->numberOfBots_);
     
    127114            {
    128115                it->setActive(true);
    129                 /*it->setMaxSpeedBack(this->maxSpeedBack_);
    130                 it->setMaxSpeedFront(this->maxSpeedFront_);
    131                 it->setMaxSpeedLeftRight(this->maxSpeedLeftRight_);
    132                 it->setMaxSpeedUpDown(this->maxSpeedUpDown_);*/
     116               
    133117            }
    134118            this->cantMove_= false;
  • code/branches/spaceraceTwo/src/modules/gametypes/SpaceRace.h

    r8970 r8979  
    4040#include "gametypes/Gametype.h"
    4141
    42 
    43 
    4442#include "SpaceRaceManager.h"
    4543
     
    5351    {
    5452        friend class RaceCheckPoint;
    55         //friend class SpaceRaceManager;
     53       
    5654
    5755        public:
     
    8583            virtual bool playerLeft(PlayerInfo* player); //!< Manages all local variables.
    8684        private:
    87             float maxSpeedBack_; float maxSpeedFront_; float maxSpeedLeftRight_; float maxSpeedUpDown_;
    8885            bool cantMove_;
    8986            std::map<PlayerInfo*, int>checkpointReached_; //The number of the last check point reached by each player.
  • code/branches/spaceraceTwo/src/modules/gametypes/SpaceRaceManager.cc

    r8970 r8979  
    8686        SUPER(SpaceRaceManager, XMLPort, xmlelement, mode);
    8787
    88         //XMLPortParam(WaypointController, "accuracy", setAccuracy, getAccuracy, xmlelement, mode).defaultValues(100.0f);
     88       
    8989        XMLPortObject(SpaceRaceManager, RaceCheckPoint, "checkpoints", addCheckpoint, getCheckpoint,  xmlelement, mode);
    9090    }
     
    155155            {
    156156                if (index > -1)this->setRadVis(player,false);
     157                        else this->getCheckpoint(0)->setRadarVisibility(false);
    157158                gametype->newCheckpointReached(check,player);
    158159                check->setRadarObjectColour(ColourValue::Green); //sets the radar colour of the checkpoint to green if it is reached, else it is red.
Note: See TracChangeset for help on using the changeset viewer.