Files
Reboot-Launcher/dependencies/reboot/Project Reboot 3.0/AttributeSet.h
Alessandro Autiero b41e22adeb <feat: New project structure>
<feat: New release>
2023-09-02 15:34:15 +02:00

48 lines
930 B
C++

#pragma once
#include "reboot.h"
class UAttributeSet : public UObject
{
public:
};
struct FGameplayAttribute
{
FString AttributeName;
void* Attribute; // Property
UStruct* AttributeOwner;
std::string GetAttributeName()
{
return AttributeName.ToString();
}
std::string GetAttributePropertyName()
{
if (!Attribute)
return "INVALIDATTRIBUTE";
return GetFNameOfProp(Attribute)->ToString();
}
};
struct FGameplayAttributeData
{
float& GetBaseValue()
{
static auto BaseValueOffset = FindOffsetStruct("/Script/GameplayAbilities.GameplayAttributeData", "BaseValue");
return *(float*)(__int64(this) + BaseValueOffset);
}
float& GetCurrentValue()
{
static auto CurrentValueOffset = FindOffsetStruct("/Script/GameplayAbilities.GameplayAttributeData", "CurrentValue");
return *(float*)(__int64(this) + CurrentValueOffset);
}
};
struct FFortGameplayAttributeData : public FGameplayAttributeData
{
};