CardRPG 1.0
 
Loading...
Searching...
No Matches
CardRPG.TriggerEffectSlot< T > Class Template Reference

A slot for effects that trigger based on certain conditions. More...

Inheritance diagram for CardRPG.TriggerEffectSlot< T >:
CardRPG.EffectSlot< T >

Public Member Functions

float CalculateModifier (int element, Type targetType, int value)
 Calculate the modifier for a specific element and target type.
 
- Public Member Functions inherited from CardRPG.EffectSlot< T >
IEnumerator AddEffect (Dueler dueler, T effect)
 Adds an effect to the slot for the specified Dueler.
 
IEnumerator RemoveEffect (Dueler dueler, T effect)
 Removes an effect from the slot for the specified Dueler.
 
List< T > GetEffects< T1 > ()
 Gets all effects of a specific type from the slot.
 
List< T > GetNegativeEffects ()
 Gets all negative effects.
 
IEnumerator RemoveNegativeEffects (Dueler dueler, int count)
 Removes a specified number of negative effects from the Dueler.
 
List< T > GetPositiveEffects ()
 Gets all positive effects.
 
IEnumerator RemovePositiveEffects (Dueler dueler, int count)
 Removes a specified number of positive effects from the Dueler.
 
void Clear (Dueler dueler)
 Clears all effects from the slot for the specified Dueler.
 

Public Attributes

List< string > uniqueEffect = new()
 A list of unique effect names to ensure each effect is only applied once.
 
- Public Attributes inherited from CardRPG.EffectSlot< T >
UnityEvent< T > OnApply = new()
 Triggers when an effect is applied.
 
UnityEvent< T > OnRemove = new()
 Triggers when an effect is removed.
 

Additional Inherited Members

- Protected Attributes inherited from CardRPG.EffectSlot< T >
readonly List< T > Effects = new()
 

Detailed Description

A slot for effects that trigger based on certain conditions.

Template Parameters
T
Type Constraints
T :ITriggerEffect 

Member Function Documentation

◆ CalculateModifier()

float CardRPG.TriggerEffectSlot< T >.CalculateModifier ( int element,
Type targetType,
int value )
inline

Calculate the modifier for a specific element and target type.

Parameters
element
targetType
value
Returns

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