(Hopefully) fixed crash when a key is pressed after the end of the race.

git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@5343 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
hikerstk
2010-05-02 13:56:05 +00:00
parent cfda49885d
commit dcdb61c663
2 changed files with 4 additions and 1 deletions

View File

@@ -403,7 +403,7 @@ void InputManager::dispatchInput(Input::InputType type, int deviceID, int btnID,
return;
}
((PlayerController*)pk->getController())->action(action, abs(value));
((Controller*)pk->getController())->action(action, abs(value));
}
// ... when in menus
else

View File

@@ -62,7 +62,10 @@ public:
virtual void finishedRace (float time) {};
virtual bool isPlayerController () const {return false;}
virtual bool isNetworkController() const {return false;}
/** Default: ignore actions. Only PlayerController get them. */
virtual void action (PlayerAction action, int value) {}
virtual const irr::core::stringw& getNamePostfix() const;
}; // Controller
#endif