17 lines
374 B
C++
17 lines
374 B
C++
#pragma once
|
|
#include "GasaAbilitySystemComponent.h"
|
|
#include "AbilitySystemInterface.h"
|
|
|
|
namespace Gasa
|
|
{
|
|
inline
|
|
UGasaAbilitySystemComp* GetAbilitySystem(UObject* Object)
|
|
{
|
|
if (Object->Implements<UAbilitySystemInterface>())
|
|
{
|
|
return Cast<UGasaAbilitySystemComp>( Cast<IAbilitySystemInterface>(Object)->GetAbilitySystemComponent() );
|
|
}
|
|
return nullptr;
|
|
}
|
|
}
|