Untitled
unknown
plain_text
2 years ago
795 B
11
Indexable
void AAuraCharacter::PossessedBy(AController* NewController)
{
Super::PossessedBy(NewController);
// Init ability actor info for the server
InitAbilityActorInfo();
}
void AAuraCharacter::OnRep_PlayerState()
{
Super::OnRep_PlayerState();
// Init ability actor info for the client
InitAbilityActorInfo();
}
void AAuraCharacter::InitAbilityActorInfo()
{
AAuraPlayerState* AuraPlayerState = GetPlayerState<AAuraPlayerState>();
if (AuraPlayerState)
{
AuraPlayerState->GetAbilitySystemComponent()->InitAbilityActorInfo(AuraPlayerState, this);
// Assigning values to inherited AbilitySystemComponent and AttributeSet
AbilitySystemComponent = AuraPlayerState->GetAbilitySystemComponent();
AttributeSet = AuraPlayerState->GetAttributeSet();
}
}
Editor is loading...
Leave a Comment