![]() |
Space Fighter
A "shmup" game for Computer Programming C++
|
Represents a type of trigger, which can be used to activate weapons. More...
#include <TriggerType.h>
Public Member Functions | |
| TriggerType () | |
| Instantiate a trigger type object. | |
| virtual | ~TriggerType () |
| TriggerType & | operator= (const TriggerType &type) |
| bool | operator== (const TriggerType &type) const |
| bool | operator!= (const TriggerType &type) const |
| bool | operator< (const TriggerType &type) const |
| bool | operator> (const TriggerType &type) const |
| const TriggerType | operator| (const TriggerType &type) const |
| TriggerType & | operator|= (const TriggerType &type) |
| const TriggerType | operator& (const TriggerType &type) const |
| TriggerType & | operator&= (const TriggerType &type) |
| const TriggerType | operator^ (const TriggerType &type) const |
| TriggerType & | operator^= (const TriggerType &type) |
| bool | Contains (const TriggerType &type) const |
| Check if the trigger type contains a specific trigger. | |
Static Public Attributes | |
| static const TriggerType | None = TriggerType(0) |
| static const TriggerType | Primary = TriggerType(1 << 0) |
| static const TriggerType | Secondary = TriggerType(1 << 1) |
| static const TriggerType | Special = TriggerType(1 << 2) |
| static const TriggerType | All = TriggerType((unsigned short)(-1)) |
Protected Member Functions | |
| TriggerType (const unsigned short value) | |
| Instantiate a trigger type object with a specific value. | |
Represents a type of trigger, which can be used to activate weapons.
Each trigger type is represented by a unique bit-mask value. This class helps to decouple the weapon system from the input system.
Definition at line 7 of file TriggerType.h.
|
inline |
Instantiate a trigger type object.
Definition at line 13 of file TriggerType.h.
|
inlinevirtual |
Definition at line 14 of file TriggerType.h.
|
inlineprotected |
Instantiate a trigger type object with a specific value.
| value | The value of the trigger type. |
Definition at line 99 of file TriggerType.h.
|
inline |
Check if the trigger type contains a specific trigger.
| type | The trigger type to check. |
Definition at line 89 of file TriggerType.h.
|
inline |
Definition at line 35 of file TriggerType.h.
|
inline |
Definition at line 62 of file TriggerType.h.
|
inline |
Definition at line 67 of file TriggerType.h.
|
inline |
Definition at line 40 of file TriggerType.h.
|
inline |
Definition at line 23 of file TriggerType.h.
|
inline |
Definition at line 30 of file TriggerType.h.
|
inline |
Definition at line 45 of file TriggerType.h.
|
inline |
Definition at line 74 of file TriggerType.h.
|
inline |
Definition at line 79 of file TriggerType.h.
|
inline |
Definition at line 50 of file TriggerType.h.
|
inline |
Definition at line 55 of file TriggerType.h.
|
static |
Definition at line 20 of file TriggerType.h.
|
static |
Definition at line 16 of file TriggerType.h.
|
static |
Definition at line 17 of file TriggerType.h.
|
static |
Definition at line 18 of file TriggerType.h.
|
static |
Definition at line 19 of file TriggerType.h.