tranek / GASDocumentation

My understanding of Unreal Engine 5's GameplayAbilitySystem plugin with a simple multiplayer sample project.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Suggestion to add to the Gameplay Effect section

ravenboilinux opened this issue · comments

Also something to note in the Gameplay Effect section is that Gameplay Effects have a property called "UIData". UIData is used for data for the UI representation of this effect(for like buffs and debuffs). UI layer can listen(or playercontroller/state) for when Gameplay Effect deactivate or activate, and use the UGameplayEffectUIData object from that effect to display to the HUD/UI. That way you can design the ui text, icons, etc from blueprints.

Now typically, I will have the ASC expose a much simpler delegate which just takes in the UGameplayEffectUIData object, and Gameplay Tag that is trigger when a Gameplay Effect activate and has UIData, and also a deactivation delegate that passes a Gameplay Tag. These two delegates are really for the UI layer, and to avoid having to pass around a huge Gameplay Effect Object.

I purposefully held back from including the UIData because I haven't had to use it yet. I feel like that's something that I would want to include a working example with. I suppose I could do a simple case where the stun effect from the meteor in the sample project displays a stun icon above the stunned characters' heads.

However, the minion characters are in minimal replication mode so they wouldn't receive the GE on clients anyways. A separate table mapping tags to UIData-like classes rather than using the GE UIData makes more sense to cover mixed and minimal replication mode.

It's something to think about for the future but I don't have time right now to work on this.

to avoid having to pass around a huge Gameplay Effect Object.

Just to clarify, we would only ever pass around a pointer to the GE class. So this shouldn't be a concern.

Thanks for the suggestion.

I can understand including a working example with the UIData since in the plug there is only single subclass which has a text Description property. I was looking at it for cases where the Gameplay Effect lives and does it business at. They do say that it does not exists for server only builds. Which would be good to understand how they exclude it from server only builds