Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6713


Ignore:
Timestamp:
Apr 13, 2010, 10:49:13 AM (15 years ago)
Author:
dafrick
Message:

Adjusted SpeedPickup such that the Engine is the actual PickupCarrier now. (and not the Pawn)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/modules/pickup/items/SpeedPickup.cc

    r6709 r6713  
    7979        this->speedMultiply_ = 1.0f;
    8080
    81         this->addTarget(ClassIdentifier<Pawn>::getIdentifier());
     81        this->addTarget(ClassIdentifier<Engine>::getIdentifier());
    8282    }
    8383
     
    166166    {
    167167        PickupCarrier* carrier = this->getCarrier();
    168         SpaceShip* ship = dynamic_cast<SpaceShip*>(carrier);
    169 
    170         if(ship == NULL)
     168        Engine* engine = dynamic_cast<Engine*>(carrier);
     169
     170        if(engine == NULL)
    171171        {
    172172            COUT(1) << "Invalid PickupCarrier in SpeedPickup." << std::endl;
    173173        }
    174         else
    175         {
    176             return ship->getEngine();
    177         }
    178 
    179         return 0;
     174       
     175        return engine;
    180176    }
    181177
Note: See TracChangeset for help on using the changeset viewer.