Emergency 20 Dokumentation  4.2.0
em5::CommandDelegate Class Reference

EMERGENCY 5 command delegate instance. More...

#include <CommandDelegate.h>

Inheritance diagram for em5::CommandDelegate:
qsf::game::CommandDelegate

Public Member Functions

 CommandDelegate ()
 Constructor. More...
 
virtual ~CommandDelegate ()
 Destructor. More...
 
virtual bool areCommandsAllowed () override
 Callback to determine whether commands are currently allowed at all. More...
 
virtual bool isCommandAllowed (const qsf::game::Command &command) override
 Callback to determine whether a certain commands is currently allowed to be checked and executed. More...
 
virtual bool isCallerAllowed (qsf::Entity &caller, const qsf::game::CommandContext &context) override
 Callback to determine whether a certain caller entity is currently allowed to be given commands. More...
 
virtual bool isTargetAllowed (const qsf::game::CommandContext &context) override
 Callback to determine whether the target given as part of the context is currently a valid command target. More...
 
virtual bool preCommandExecution (const qsf::game::Command &command, const std::vector< qsf::Entity * > &callers, qsf::game::CommandContext &context) override
 Callback to determine whether the complete command context is currently allowed to be executed. More...
 
virtual bool preCommandExecution (const qsf::game::Command &command, qsf::game::CommandContext &context) override
 Callback to determine whether the complete command context is currently allowed to be executed. More...
 
virtual void postCommandExecution (const qsf::game::Command &command, const qsf::game::CommandContext &context) override
 Callback to inform the delegate when a command was just executed. More...
 
virtual qsf::game::CommandModegetDefaultCommandMode () override
 Return the CommandMode which should be used as default. More...
 
- Public Member Functions inherited from qsf::game::CommandDelegate
 CommandDelegate ()
 Default constructor. More...
 

Detailed Description

EMERGENCY 5 command delegate instance.

Constructor & Destructor Documentation

em5::CommandDelegate::CommandDelegate ( )

Constructor.

em5::CommandDelegate::~CommandDelegate ( )
inlinevirtual

Destructor.

Reimplemented from qsf::game::CommandDelegate.

Member Function Documentation

bool em5::CommandDelegate::areCommandsAllowed ( )
inlineoverridevirtual

Callback to determine whether commands are currently allowed at all.

Reimplemented from qsf::game::CommandDelegate.

virtual qsf::game::CommandMode* em5::CommandDelegate::getDefaultCommandMode ( )
overridevirtual

Return the CommandMode which should be used as default.

Remarks
the returned pointer must be valid. The ownership of the returned instance goes to the caller

Reimplemented from qsf::game::CommandDelegate.

virtual bool em5::CommandDelegate::isCallerAllowed ( qsf::Entity caller,
const qsf::game::CommandContext context 
)
overridevirtual

Callback to determine whether a certain caller entity is currently allowed to be given commands.

Reimplemented from qsf::game::CommandDelegate.

bool em5::CommandDelegate::isCommandAllowed ( const qsf::game::Command command)
inlineoverridevirtual

Callback to determine whether a certain commands is currently allowed to be checked and executed.

Reimplemented from qsf::game::CommandDelegate.

virtual bool em5::CommandDelegate::isTargetAllowed ( const qsf::game::CommandContext context)
overridevirtual

Callback to determine whether the target given as part of the context is currently a valid command target.

Reimplemented from qsf::game::CommandDelegate.

virtual void em5::CommandDelegate::postCommandExecution ( const qsf::game::Command command,
const qsf::game::CommandContext context 
)
overridevirtual

Callback to inform the delegate when a command was just executed.

Reimplemented from qsf::game::CommandDelegate.

virtual bool em5::CommandDelegate::preCommandExecution ( const qsf::game::Command command,
const std::vector< qsf::Entity * > &  callers,
qsf::game::CommandContext context 
)
overridevirtual

Callback to determine whether the complete command context is currently allowed to be executed.

Remarks
You may also manipulate the context here - but use this with care!

Reimplemented from qsf::game::CommandDelegate.

virtual bool em5::CommandDelegate::preCommandExecution ( const qsf::game::Command command,
qsf::game::CommandContext context 
)
overridevirtual

Callback to determine whether the complete command context is currently allowed to be executed.

Remarks
You may also manipulate the context here - but use this with care!

Reimplemented from qsf::game::CommandDelegate.


The documentation for this class was generated from the following files: