tranek / GASDocumentation

My understanding of Unreal Engine 5's GameplayAbilitySystem plugin with a simple multiplayer sample project.
MIT License
4.39k stars 806 forks source link

UE5.3 - AttributeSet Generated Error #134

Closed hotddul closed 3 months ago

hotddul commented 5 months ago

I usually use version UE5.2, but recently changed to UE5.3 and am now using GameplayAbilitySystem.

While creating and working on a new project, I assigned the AttributeSet created in PlayerState to PlayerCharacter and discovered a problem in the process of creating and using it as a Blueprint descendant, where the AttributeSet was not created properly. I thought this was related to item 9.4 of GASDocumentation written earlier, but it was a slightly different problem.

While I was unable to solve the problem, I thought that TObjectPtr was not generating data properly and crashed during the creation of blueprint descendants, so I changed it to Raw Pointer ( * ).

The problem has since been resolved. I'm not sure if there was a change in TObjectPtr in UE5.3, but it certainly seems to be crashing. If anyone is experiencing this problem, try modifying the source as follows.

Before :

    UPROPERTY(VisibleAnywhere)
    TObjectPtr<UPBAbilitySystemComponent> AbilitySystemComponent;

    UPROPERTY()
    TObjectPtr<UAttributeSet> AttributeSet;
After :

    UPROPERTY(VisibleAnywhere)
    UPBAbilitySystemComponent* AbilitySystemComponent;

    UPROPERTY()
    UAttributeSet* AttributeSet;