Add PHY class framework

This commit is contained in:
2026-04-26 01:06:46 +08:00
parent d392c103ca
commit ddb5f599f9
13 changed files with 353 additions and 0 deletions

View File

@@ -4,6 +4,8 @@
#include UE_INLINE_GENERATED_CPP_BY_NAME(PHYPlayerState)
#include "Class/PHYClassComponent.h"
#include "Class/PHYClassSettings.h"
#include "GGA_AbilitySystemComponent.h"
APHYPlayerState::APHYPlayerState(const FObjectInitializer& ObjectInitializer)
@@ -14,6 +16,9 @@ APHYPlayerState::APHYPlayerState(const FObjectInitializer& ObjectInitializer)
AbilitySystemComponent = CreateDefaultSubobject<UGGA_AbilitySystemComponent>(TEXT("AbilitySystemComponent"));
AbilitySystemComponent->SetIsReplicated(true);
AbilitySystemComponent->SetReplicationMode(EGameplayEffectReplicationMode::Mixed);
ClassComponent = CreateDefaultSubobject<UPHYClassComponent>(TEXT("ClassComponent"));
ClassComponent->SetClassTag(GetDefault<UPHYClassSettings>()->DefaultPlayerClassTag);
}
UAbilitySystemComponent* APHYPlayerState::GetAbilitySystemComponent() const