Clarified one method by using a enum type instead of simply 'int'

git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@4756 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
auria 2010-02-17 23:35:25 +00:00
parent d4095bf3be
commit bbd2ecb4c4
3 changed files with 3 additions and 3 deletions

View File

@ -311,7 +311,7 @@ void ThreeStrikesBattle::raceResultOrder( int* order )
} // raceResultOrder } // raceResultOrder
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
bool ThreeStrikesBattle::acceptPowerup(const int type) const bool ThreeStrikesBattle::acceptPowerup(const PowerupType type) const
{ {
// these powerups don't make much sense in battle mode // these powerups don't make much sense in battle mode
if(type == POWERUP_PARACHUTE || type == POWERUP_ANVIL || if(type == POWERUP_PARACHUTE || type == POWERUP_ANVIL ||

View File

@ -59,7 +59,7 @@ public:
virtual RaceGUI::KartIconDisplayInfo* getKartsDisplayInfo(); virtual RaceGUI::KartIconDisplayInfo* getKartsDisplayInfo();
virtual bool raceHasLaps(){ return false; } virtual bool raceHasLaps(){ return false; }
virtual void moveKartAfterRescue(Kart* kart, btRigidBody* body); virtual void moveKartAfterRescue(Kart* kart, btRigidBody* body);
virtual bool acceptPowerup(const int type) const; virtual bool acceptPowerup(const PowerupType type) const;
virtual std::string getIdent() const; virtual std::string getIdent() const;

View File

@ -205,7 +205,7 @@ public:
/** called when a bonus box is hit, to determine which types of powerups are allowed /** called when a bonus box is hit, to determine which types of powerups are allowed
in each game mode. By default all are accepted, override in child classes to get in each game mode. By default all are accepted, override in child classes to get
a different behaviour */ a different behaviour */
virtual bool acceptPowerup(const int type) const { return true; } virtual bool acceptPowerup(const PowerupType type) const { return true; }
/** Called by the code that draws the list of karts on the race GUI /** Called by the code that draws the list of karts on the race GUI
* to know what needs to be drawn in the current mode * to know what needs to be drawn in the current mode