Navigation
API > API/Plugins > API/Plugins/GameplayAbilities > API/Plugins/GameplayAbilities/Abilities > API/Plugins/GameplayAbilities/Abilities/Tasks
Inheritance Hierarchy
- UObjectBase
- UObjectBaseUtility
- UObject
- UGameplayTask
- UAbilityTask
- UAbilityTask_WaitAttributeChangeRatioThreshold
References
| Module | GameplayAbilities |
| Header | /Engine/Plugins/Runtime/GameplayAbilities/Source/GameplayAbilities/Public/Abilities/Tasks/AbilityTask_WaitAttributeChangeRatioThreshold.h |
| Include | #include "Abilities/Tasks/AbilityTask_WaitAttributeChangeRatioThreshold.h" |
Syntax
UCLASS&40;&41;
class UAbilityTask_WaitAttributeChangeRatioThreshold : public UAbilityTask
Remarks
Waits for the ratio between two attributes to match a threshold
Variables
| Type | Name | Description | |
|---|---|---|---|
| FGameplayAttribute | AttributeDenominator | ||
| FGameplayAttribute | AttributeNumerator | ||
| bool | bMatchedComparisonLastAttributeChange | ||
| bool | bTriggerOnce | ||
| FTimerHandle | CheckAttributeTimer | Timer used when either numerator or denominator attribute is changed to delay checking of ratio to avoid false positives (MaxHealth changed before Health updates accordingly) | |
| TEnumAsByte< EWaitAttributeChangeComparison::Type > | ComparisonType | ||
| float | ComparisonValue | ||
| TObjectPtr< UAbilitySystemComponent > | ExternalOwner | ||
| float | LastAttributeDenominatorValue | ||
| float | LastAttributeNumeratorValue | ||
| FWaitAttributeChangeRatioThresholdDelegate | OnChange | ||
| FDelegateHandle | OnDenominatorAttributeChangeDelegateHandle | ||
| FDelegateHandle | OnNumeratorAttributeChangeDelegateHandle |
Constructors
| Type | Name | Description | |
|---|---|---|---|
UAbilityTask_WaitAttributeChangeRatioThreshold
(
const FObjectInitializer& ObjectInitializer |
Functions
| Type | Name | Description | |
|---|---|---|---|
| bool | DoesValuePassComparison
(
float ValueNumerator, |
||
| UAbilitySystemComponent * | |||
| void | |||
| void | OnDenominatorAttributeChange
(
const FOnAttributeChangeData& CallbackData |
||
| void | OnNumeratorAttributeChange
(
const FOnAttributeChangeData& CallbackData |
||
| void | |||
| UAbilityTask_WaitAttributeChangeRatioThreshold * | WaitForAttributeChangeRatioThreshold
(
UGameplayAbility* OwningAbility, |
Wait on attribute ratio change meeting a comparison threshold. |
Overridden from UGameplayTask
| Type | Name | Description | |
|---|---|---|---|
| void | Activate () |
Called to trigger the actual task once the delegates have been set up Note that the default implementation does nothing and you don't have to call it | |
| void | OnDestroy
(
bool bInOwnerFinished |
End and CleanUp the task - may be called by the task itself or by the task owner if the owner is ending. |