HoverRace
2.0
|
Abstract base class which allows us a simple reference to arbitrary functors of type ControlActionImpl (which bind a class via a template parameter). More...
#include <ControlAction.h>
Public Member Functions | |
ControlAction () | |
ControlAction (const std::string &name, int listOrder) | |
virtual | ~ControlAction () |
int | GetListOrder () const noexcept |
const std::string & | GetName () const noexcept |
virtual void | operator() (T eventValue)=0 |
Protected Attributes | |
int | listOrder |
std::string | name |
Abstract base class which allows us a simple reference to arbitrary functors of type ControlActionImpl (which bind a class via a template parameter).
Unfortunately, this must use virtual functions to work correctly, which is not optimal, but is the best the language can do.
To create a functor, derive the ControlAction class.
|
inline |
|
inline |
|
inlinevirtual |
|
inlinenoexcept |
|
inlinenoexcept |
|
pure virtual |
Implemented in HoverRace::Control::Action< T, Val >, HoverRace::Control::LookBackAction, HoverRace::Control::BrakeAction, HoverRace::Control::ChangeItemAction, HoverRace::Control::PowerupAction, HoverRace::Control::JumpAction, HoverRace::Control::TurnRightAction, HoverRace::Control::TurnLeftAction, HoverRace::Control::BlankAction, HoverRace::Control::EngineAction, and HoverRace::Control::PlayerEffectAction.
|
protected |
|
protected |