GASATHON/Project/Source/Gasa/AbilitySystem/GasaAttributeSet_Inlines.h

162 lines
4.5 KiB
C
Raw Normal View History

2024-10-22 10:25:27 -07:00
// Generated by GasaEditor/GasaGen/GasaGen_AttributeSets.cpp
2024-04-21 15:56:57 -07:00
#pragma once
#include "GasaAttributeSet.h"
#include "AbilitySystemComponent.h"
#pragma region Attribute Setters
2024-04-21 15:56:57 -07:00
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetHealth( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetHealthAttribute(), NewVal );
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetMana( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetManaAttribute(), NewVal );
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetStrength( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetStrengthAttribute(), NewVal );
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetIntelligence( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetIntelligenceAttribute(), NewVal );
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetResilience( float NewVal )
2024-04-21 15:56:57 -07:00
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetResilienceAttribute(), NewVal );
2024-04-21 15:56:57 -07:00
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetVigor( float NewVal )
2024-04-21 15:56:57 -07:00
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetVigorAttribute(), NewVal );
2024-04-21 15:56:57 -07:00
};
}
FORCEINLINE
2024-10-22 10:25:27 -07:00
void UGasaAttributeSet::SetMaxHealth( float NewVal )
2024-04-21 15:56:57 -07:00
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
2024-10-22 10:25:27 -07:00
AbilityComp->SetNumericAttributeBase( GetMaxHealthAttribute(), NewVal );
2024-04-21 15:56:57 -07:00
};
}
FORCEINLINE
void UGasaAttributeSet::SetMaxMana( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetMaxManaAttribute(), NewVal );
};
}
2024-10-22 13:52:42 -07:00
FORCEINLINE
void UGasaAttributeSet::SetArmor( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetArmorAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetArmorPenentration( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetArmorPenentrationAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetBlockChance( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetBlockChanceAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetCriticalHitChance( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetCriticalHitChanceAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetCriticalHitDamage( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetCriticalHitDamageAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetCriticalHitResistance( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetCriticalHitResistanceAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetHealthRegeneration( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetHealthRegenerationAttribute(), NewVal );
};
}
FORCEINLINE
void UGasaAttributeSet::SetManaRegeneration( float NewVal )
{
UAbilitySystemComponent* AbilityComp = GetOwningAbilitySystemComponent();
if ( ensure( AbilityComp ) )
{
AbilityComp->SetNumericAttributeBase( GetManaRegenerationAttribute(), NewVal );
};
}
#pragma endregion Attribute Setters
2024-04-21 15:56:57 -07:00
namespace Gasa
{
inline UGasaAttributeSet const* GetAttributeSet( UAbilitySystemComponent* ASC )
{
return Cast<UGasaAttributeSet>( ASC->GetAttributeSet( UGasaAttributeSet::StaticClass() ) );
}
}