Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8734 for code/branches


Ignore:
Timestamp:
Jul 6, 2011, 10:50:18 PM (13 years ago)
Author:
dafrick
Message:

Fix for AI and rockets.

Location:
code/branches/ai2/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/ai2/src/modules/weapons/projectiles/SimpleRocket.cc

    r8706 r8734  
    100100        if ( GameMode::isMaster() )
    101101        {
    102 
    103 
    104102            this->setAngularVelocity(this->getOrientation() * this->localAngularVelocity_);
    105103            this->setVelocity( this->getOrientation()*WorldEntity::FRONT*this->getVelocity().length() );
  • code/branches/ai2/src/modules/weapons/projectiles/SimpleRocket.h

    r8706 r8734  
    7575            */
    7676            inline void moveFrontBack(float value)
    77             { this->moveFrontBack(Vector2(value, 0)); }
     77                { this->moveFrontBack(Vector2(value, 0)); }
    7878            /**
    7979            @brief Moves the SimpleRocket in the Right/Left-direction by the specifed amount.
     
    8181            */
    8282            inline void moveRightLeft(float value)
    83             { this->moveRightLeft(Vector2(value, 0)); }
     83                { this->moveRightLeft(Vector2(value, 0)); }
    8484            /**
    8585            @brief Moves the SimpleRocket in the Up/Down-direction by the specifed amount.
     
    8787            */
    8888            inline void moveUpDown(float value)
    89             { this->moveUpDown(Vector2(value, 0)); }
     89                { this->moveUpDown(Vector2(value, 0)); }
    9090
    9191            /**
     
    9494            */
    9595            inline void rotateYaw(float value)
    96             { this->rotateYaw(Vector2(value, 0)); }
     96                { this->rotateYaw(Vector2(value, 0)); }
    9797            /**
    9898            @brief Rotates the SimpleRocket around the x-axis by the specifed amount.
     
    100100            */
    101101            inline void rotatePitch(float value)
    102             {
    103                 this->rotatePitch(Vector2(value, 0)); }
     102                { this->rotatePitch(Vector2(value, 0)); }
    104103            /**
    105104            @brief Rotates the SimpleRocket around the z-axis by the specifed amount.
     
    107106            */
    108107            inline void rotateRoll(float value)
    109             {
    110                 this->rotateRoll(Vector2(value, 0)); }
     108                { this->rotateRoll(Vector2(value, 0)); }
    111109
    112110            void setOwner(Pawn* owner);
     
    115113
    116114            inline bool hasFuel() const
    117             { return this->fuel_; }
     115                { return this->fuel_; }
    118116
    119117
  • code/branches/ai2/src/orxonox/infos/PlayerInfo.cc

    r8706 r8734  
    235235
    236236        this->controllableEntity_->setController(0);
    237         this->controllableEntity_->destroyHud(); // HACK-ish
     237        if(this->isHumanPlayer()) // TODO: Multiplayer?
     238            this->controllableEntity_->destroyHud(); // HACK-ish
    238239       
    239240//        this->controllableEntity_ = this->previousControllableEntity_.back();
     
    248249
    249250         // HACK-ish
    250         if(this->controllableEntity_ != NULL)
     251        if(this->controllableEntity_ != NULL && this->isHumanPlayer())
    251252            this->controllableEntity_->createHud();
    252253
Note: See TracChangeset for help on using the changeset viewer.