Fixes for GasaGen_AttributeSets
This commit is contained in:
@ -13,14 +13,14 @@ struct GASA_API FAttributeSetField : public FTableRowBase
|
||||
|
||||
FAttributeSetField()
|
||||
: Name("Provide_Name")
|
||||
, Category("Optional Category")
|
||||
, Category("Provide Category")
|
||||
, Description("Provide Description")
|
||||
, BaseValue(0)
|
||||
, bUseMinAttribute(false)
|
||||
, bUseMaxAttribute(false)
|
||||
, MinAttribute("Attribute behaving has minimum value")
|
||||
, MinAttribute("")
|
||||
, MinValue(0)
|
||||
, MaxAttribute("Attribute behaving has maximum value")
|
||||
, MaxAttribute("")
|
||||
, MaxValue(0)
|
||||
{}
|
||||
virtual ~FAttributeSetField()
|
||||
@ -48,13 +48,13 @@ struct GASA_API FAttributeSetField : public FTableRowBase
|
||||
bool bUseMaxAttribute;
|
||||
|
||||
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Gameplay Attribute", meta =( EditCondition="bUseMinAttribute", EditConditionHides))
|
||||
FString MinAttribute;
|
||||
FName MinAttribute;
|
||||
|
||||
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Gameplay Attribute", meta =( EditCondition="bUseMinAttribute==false", EditConditionHides))
|
||||
float MinValue;
|
||||
|
||||
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Gameplay Attribute", meta =( EditCondition="bUseMaxAttribute", EditConditionHides))
|
||||
FString MaxAttribute;
|
||||
FName MaxAttribute;
|
||||
|
||||
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Gameplay Attribute", meta =( EditCondition="bUseMaxAttribute==false", EditConditionHides))
|
||||
float MaxValue;
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Generated by GasaGen/GasaGen_UGasaAttributeSet.cpp
|
||||
// Generated by GasaEditor/GasaGen/GasaGen_AttributeSets.cpp
|
||||
#include "GasaAttributeSet.h"
|
||||
#include "GasaAttributeSet_Inlines.h"
|
||||
#include "EffectProperties.h"
|
||||
@ -8,15 +8,21 @@
|
||||
#include "Networking/GasaNetLibrary.h"
|
||||
#include "GameplayEffectExtension.h"
|
||||
|
||||
UGasaAttributeSet::UGasaAttributeSet()
|
||||
{
|
||||
InitHealth( 100.f );
|
||||
InitMaxHealth( 100.f );
|
||||
InitMana( 50.f );
|
||||
InitMaxMana( 50.f );
|
||||
}
|
||||
UGasaAttributeSet::UGasaAttributeSet() {}
|
||||
|
||||
#pragma region Rep Notifies
|
||||
void UGasaAttributeSet::Client_OnRep_Health( FGameplayAttributeData& PrevHealth )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Health ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), Health, PrevHealth );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_Mana( FGameplayAttributeData& PrevMana )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Mana ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), Mana, PrevMana );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_Strength( FGameplayAttributeData& PrevStrength )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
@ -45,24 +51,12 @@ void UGasaAttributeSet::Client_OnRep_Vigor( FGameplayAttributeData& PrevVigor )
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Vigor ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), Vigor, PrevVigor );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_Health( FGameplayAttributeData& PrevHealth )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Health ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), Health, PrevHealth );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_MaxHealth( FGameplayAttributeData& PrevMaxHealth )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, MaxHealth ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), MaxHealth, PrevMaxHealth );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_Mana( FGameplayAttributeData& PrevMana )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
static FProperty* UGasaAttributeSetProperty = FindFieldChecked<FProperty>( StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Mana ) );
|
||||
GetOwningAbilitySystemComponentChecked()->SetBaseAttributeValueFromReplication( FGameplayAttribute( UGasaAttributeSetProperty ), Mana, PrevMana );
|
||||
}
|
||||
void UGasaAttributeSet::Client_OnRep_MaxMana( FGameplayAttributeData& PrevMaxMana )
|
||||
{
|
||||
// From GAMEPLAYATTRIBUTE_REPNOTIFY
|
||||
@ -77,6 +71,14 @@ void UGasaAttributeSet::PostGameplayEffectExecute( FGameplayEffectModCallbackDat
|
||||
FEffectProperties Props;
|
||||
Props.Populate( Data );
|
||||
|
||||
if ( Data.EvaluatedData.Attribute == GetHealthAttribute() )
|
||||
{
|
||||
SetHealth( FMath::Clamp( GetHealth(), 0, GetMaxHealth() ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetManaAttribute() )
|
||||
{
|
||||
SetMana( FMath::Clamp( GetMana(), 0, GetMaxMana() ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetStrengthAttribute() )
|
||||
{
|
||||
SetStrength( FMath::Clamp( GetStrength(), 0, 999.000000 ) );
|
||||
@ -93,18 +95,10 @@ void UGasaAttributeSet::PostGameplayEffectExecute( FGameplayEffectModCallbackDat
|
||||
{
|
||||
SetVigor( FMath::Clamp( GetVigor(), 0, 999.000000 ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetHealthAttribute() )
|
||||
{
|
||||
SetHealth( FMath::Clamp( GetHealth(), 0, GetMaxHealth() ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetMaxHealthAttribute() )
|
||||
{
|
||||
SetMaxHealth( FMath::Clamp( GetMaxHealth(), 0, 99999.000000 ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetManaAttribute() )
|
||||
{
|
||||
SetMana( FMath::Clamp( GetMana(), 0, GetMaxMana() ) );
|
||||
}
|
||||
if ( Data.EvaluatedData.Attribute == GetMaxManaAttribute() )
|
||||
{
|
||||
SetMaxMana( FMath::Clamp( GetMaxMana(), 0, 99999.000000 ) );
|
||||
@ -115,6 +109,14 @@ void UGasaAttributeSet::PreAttributeChange( FGameplayAttribute const& Attribute,
|
||||
{
|
||||
Super::PreAttributeChange( Attribute, NewValue );
|
||||
|
||||
if ( Attribute == GetHealthAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, GetMaxHealth() );
|
||||
}
|
||||
if ( Attribute == GetManaAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, GetMaxMana() );
|
||||
}
|
||||
if ( Attribute == GetStrengthAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, 999.000000 );
|
||||
@ -131,18 +133,10 @@ void UGasaAttributeSet::PreAttributeChange( FGameplayAttribute const& Attribute,
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, 999.000000 );
|
||||
}
|
||||
if ( Attribute == GetHealthAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, GetMaxHealth() );
|
||||
}
|
||||
if ( Attribute == GetMaxHealthAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, 99999.000000 );
|
||||
}
|
||||
if ( Attribute == GetManaAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, GetMaxMana() );
|
||||
}
|
||||
if ( Attribute == GetMaxManaAttribute() )
|
||||
{
|
||||
NewValue = FMath::Clamp( NewValue, 0, 99999.000000 );
|
||||
@ -153,12 +147,12 @@ void UGasaAttributeSet::GetLifetimeReplicatedProps( TArray<FLifetimeProperty>& O
|
||||
{
|
||||
Super::GetLifetimeReplicatedProps( OutLifetimeProps );
|
||||
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Health );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Mana );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Strength );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Intelligence );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Resilience );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Vigor );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Health );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, MaxHealth );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, Mana );
|
||||
DOREPLIFETIME_DEFAULT_GAS( UGasaAttributeSet, MaxMana );
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Generated by GasaGen/GasaGen_UGasaAttributeSet.cpp
|
||||
// Generated by GasaEditor/GasaGen/GasaGen_AttributeSets.cpp
|
||||
#pragma once
|
||||
|
||||
#include "AttributeSet.h"
|
||||
@ -11,28 +11,36 @@ class GASA_API UGasaAttributeSet : public UAttributeSet
|
||||
public:
|
||||
UGasaAttributeSet();
|
||||
|
||||
// Primary Attribute Fields
|
||||
// Vital Attributes
|
||||
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Strength, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Health, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Vital" )
|
||||
FGameplayAttributeData Health;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Mana, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Vital" )
|
||||
FGameplayAttributeData Mana;
|
||||
|
||||
// Primary Attributes
|
||||
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Strength, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Primary" )
|
||||
FGameplayAttributeData Strength;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Intelligence, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Intelligence, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Primary" )
|
||||
FGameplayAttributeData Intelligence;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Resilience, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Resilience, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Primary" )
|
||||
FGameplayAttributeData Resilience;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Vigor, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Vigor, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Primary" )
|
||||
FGameplayAttributeData Vigor;
|
||||
|
||||
// Vital Attribute Fields
|
||||
// Secondary Attributes
|
||||
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Health, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
FGameplayAttributeData Health;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_MaxHealth, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_MaxHealth, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Secondary" )
|
||||
FGameplayAttributeData MaxHealth;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_Mana, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
FGameplayAttributeData Mana;
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_MaxMana, EditAnywhere, BlueprintReadWrite, Category = "Attributes" )
|
||||
UPROPERTY( ReplicatedUsing = Client_OnRep_MaxMana, EditAnywhere, BlueprintReadWrite, Category = "Attributes|Secondary" )
|
||||
FGameplayAttributeData MaxMana;
|
||||
|
||||
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Health( FGameplayAttributeData& PrevHealth );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Mana( FGameplayAttributeData& PrevMana );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Strength( FGameplayAttributeData& PrevStrength );
|
||||
UFUNCTION()
|
||||
@ -42,15 +50,21 @@ public:
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Vigor( FGameplayAttributeData& PrevVigor );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Health( FGameplayAttributeData& PrevHealth );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_MaxHealth( FGameplayAttributeData& PrevMaxHealth );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_Mana( FGameplayAttributeData& PrevMana );
|
||||
UFUNCTION()
|
||||
void Client_OnRep_MaxMana( FGameplayAttributeData& PrevMaxMana );
|
||||
|
||||
#pragma region Getters
|
||||
static FGameplayAttribute GetHealthAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Health ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetManaAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Mana ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetStrengthAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Strength ) );
|
||||
@ -71,48 +85,47 @@ public:
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Vigor ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetHealthAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Health ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetMaxHealthAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, MaxHealth ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetManaAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, Mana ) );
|
||||
return Prop;
|
||||
}
|
||||
static FGameplayAttribute GetMaxManaAttribute()
|
||||
{
|
||||
static FProperty* Prop = FindFieldChecked<FProperty>( UGasaAttributeSet::StaticClass(), GET_MEMBER_NAME_CHECKED( UGasaAttributeSet, MaxMana ) );
|
||||
return Prop;
|
||||
}
|
||||
|
||||
FORCEINLINE float GetHealth() const { return Health.GetCurrentValue(); }
|
||||
FORCEINLINE float GetMana() const { return Mana.GetCurrentValue(); }
|
||||
FORCEINLINE float GetStrength() const { return Strength.GetCurrentValue(); }
|
||||
FORCEINLINE float GetIntelligence() const { return Intelligence.GetCurrentValue(); }
|
||||
FORCEINLINE float GetResilience() const { return Resilience.GetCurrentValue(); }
|
||||
FORCEINLINE float GetVigor() const { return Vigor.GetCurrentValue(); }
|
||||
FORCEINLINE float GetHealth() const { return Health.GetCurrentValue(); }
|
||||
FORCEINLINE float GetMaxHealth() const { return MaxHealth.GetCurrentValue(); }
|
||||
FORCEINLINE float GetMana() const { return Mana.GetCurrentValue(); }
|
||||
FORCEINLINE float GetMaxMana() const { return MaxMana.GetCurrentValue(); }
|
||||
#pragma endregion Getters
|
||||
#pragma endregion Getters
|
||||
|
||||
#pragma region Setters
|
||||
FORCEINLINE void
|
||||
SetStrength( float NewVal );
|
||||
FORCEINLINE void SetHealth( float NewVal );
|
||||
FORCEINLINE void SetMana( float NewVal );
|
||||
FORCEINLINE void SetStrength( float NewVal );
|
||||
FORCEINLINE void SetIntelligence( float NewVal );
|
||||
FORCEINLINE void SetResilience( float NewVal );
|
||||
FORCEINLINE void SetVigor( float NewVal );
|
||||
FORCEINLINE void SetHealth( float NewVal );
|
||||
FORCEINLINE void SetMaxHealth( float NewVal );
|
||||
FORCEINLINE void SetMana( float NewVal );
|
||||
FORCEINLINE void SetMaxMana( float NewVal );
|
||||
|
||||
FORCEINLINE void InitHealth( float NewVal )
|
||||
{
|
||||
Health.SetBaseValue( NewVal );
|
||||
Health.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitMana( float NewVal )
|
||||
{
|
||||
Mana.SetBaseValue( NewVal );
|
||||
Mana.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitStrength( float NewVal )
|
||||
{
|
||||
Strength.SetBaseValue( NewVal );
|
||||
@ -133,21 +146,11 @@ public:
|
||||
Vigor.SetBaseValue( NewVal );
|
||||
Vigor.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitHealth( float NewVal )
|
||||
{
|
||||
Health.SetBaseValue( NewVal );
|
||||
Health.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitMaxHealth( float NewVal )
|
||||
{
|
||||
MaxHealth.SetBaseValue( NewVal );
|
||||
MaxHealth.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitMana( float NewVal )
|
||||
{
|
||||
Mana.SetBaseValue( NewVal );
|
||||
Mana.SetCurrentValue( NewVal );
|
||||
}
|
||||
FORCEINLINE void InitMaxMana( float NewVal )
|
||||
{
|
||||
MaxMana.SetBaseValue( NewVal );
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Generated by GasaGen/GasaGen_UGasaAttributeSet.cpp
|
||||
// Generated by GasaEditor/GasaGen/GasaGen_AttributeSets.cpp
|
||||
#pragma once
|
||||
|
||||
#include "GasaAttributeSet.h"
|
||||
@ -6,6 +6,24 @@
|
||||
|
||||
#pragma region Attribute Setters
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetHealth( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
if ( ensure( AbilityComp ) )
|
||||
{
|
||||
AbilityComp->SetNumericAttributeBase( GetHealthAttribute(), NewVal );
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetMana( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
if ( ensure( AbilityComp ) )
|
||||
{
|
||||
AbilityComp->SetNumericAttributeBase( GetManaAttribute(), NewVal );
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetStrength( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
@ -42,15 +60,6 @@ void UGasaAttributeSet::SetVigor( float NewVal )
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetHealth( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
if ( ensure( AbilityComp ) )
|
||||
{
|
||||
AbilityComp->SetNumericAttributeBase( GetHealthAttribute(), NewVal );
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetMaxHealth( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
@ -60,15 +69,6 @@ void UGasaAttributeSet::SetMaxHealth( float NewVal )
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetMana( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
if ( ensure( AbilityComp ) )
|
||||
{
|
||||
AbilityComp->SetNumericAttributeBase( GetManaAttribute(), NewVal );
|
||||
};
|
||||
}
|
||||
FORCEINLINE
|
||||
void UGasaAttributeSet::SetMaxMana( float NewVal )
|
||||
{
|
||||
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
|
||||
|
Reference in New Issue
Block a user