comp::ChargeAbility_Behavior Class Referenceabstract

#include <ChargeAbility_Behavior.hpp>

Public Member Functions

 ChargeAbility_Behavior (iv::Instance *inst, Ability *m_ability, iv::Attr< int > *m_charges)
 
- Public Member Functions inherited from comp::Ability_Behavior
 Ability_Behavior (iv::Instance *, Ability *m_ability)
 
iv::Instanceinstance () const
 

Public Attributes

iv::ClientMarker cm
 
- Public Attributes inherited from comp::Ability_Behavior
iv::ClientMarker cm
 

Protected Member Functions

virtual void ChargeAbilityActivated ()=0
 
virtual void AbilityActivated () override
 
- Protected Member Functions inherited from comp::Ability_Behavior
void AbilityEnable (bool)
 
Abilityability ()
 

Detailed Description

Each use of the ability depletes one charge from the model given in constructor. Ability gets disabled and can not be activated when charges are on 0. Does not provide any mechanism for refilling charges (that must be provided by another behavior).

Definition at line 14 of file ChargeAbility_Behavior.hpp.

Constructor & Destructor Documentation

◆ ChargeAbility_Behavior()

comp::ChargeAbility_Behavior::ChargeAbility_Behavior ( iv::Instance inst,
Ability m_ability,
iv::Attr< int > *  m_charges 
)

Definition at line 8 of file ChargeAbility_Behavior.cpp.

Member Function Documentation

◆ ChargeAbilityActivated()

virtual void comp::ChargeAbility_Behavior::ChargeAbilityActivated ( )
protectedpure virtual

◆ AbilityActivated()

void comp::ChargeAbility_Behavior::AbilityActivated ( )
overrideprotectedvirtual

Implements comp::Ability_Behavior.

Definition at line 27 of file ChargeAbility_Behavior.cpp.

Member Data Documentation

◆ cm

iv::ClientMarker comp::ChargeAbility_Behavior::cm

Definition at line 17 of file ChargeAbility_Behavior.hpp.


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