-
Notifications
You must be signed in to change notification settings - Fork 810
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[UPD] GameplayCueLocal handlers refreshed to use UGameplayCueManager static functions #66
base: master
Are you sure you want to change the base?
Conversation
…static functions - Now we are using the avatar as the Target for a better consistency. See: InvokeGameplayCueEvent - These static functions also call `Add/RemoveLooseGameplayTag` on the target's ASC, which might be convenient for gameplay
Those I'm not entirely convinced on the AvatarActor yet, but that's not saying that it's wrong. I'm trying to think of a case where you could have an OwnerActor but not an AvatarActor where you would still want GCs to fire. I believe that there are guards in GAS code for the scenario of having an OwnerActor but no AvatarActor so Epic is expecting that to happen. I'm imagining if you're in a spectator where the ASC is on the PlayerState but you don't set the AvatarActor as the SpectatorPawn (we might want to set that as the AvatarActor anyway). We'd still want to trigger GCs locally. This scenario breaks down if we're using an ASC proxy, but that's non-standard GAS. It really depends on how the game is architected. The OwnerActor seems to me to be a more general catch-all case. That said, I see the benefits of using the AvatarActor for some of the internal debug code there - printing out a character's name versus a PlayerState's name is more useful. |
Hey Dan! I agree, The AvatarActor part concept is introduced in |
Yep, let's circle back to it in UE5. Thanks!
I believe that I've done some things where I execute a local GC but don't need the local player's AvatarActor. For example, when a replicated Actor in the world is destroyed, I might hook into its Anyway, I think it comes down to engineer/designer choice if you want the |
I agree, with my latest commit I provide a more generic solution, which can be used in any actor that implements the receiving interface. In addition, only those actors with an ASC can benefit from the loose tag system :) Might also want to remove the local |
If they are going to pass in a TargetActor as a parameter, then they might as well be static functions in a BlueprintFunctionLibrary. Because at that point they are not coupled at all to the ASC where the functions live. I can't comment on those functions though since I'm not looking at UE5 for GASDocumentation until it's released.
I'm not actually familiar with that bool in regards to remote cueing. If those _NonReplicated functions are what you want to expose to BP, then just make a static wrapper function in BlueprintFunctionLibrary class and let them handle internally whether or not suppression should happen. |
Indeed, I agree. In fact this conversation we had about "remote cueing", covering the examples you exposed should be all dealt differently, as you comment, in a BPFL function (for example). While at the same time, if you want to keep such functionality in the ASC without passing in a TargetActor, and still complying with the standardized approach, then we might fall back to the implementation of
Right, revising your comments I can draw a conclusion. To sum up, my next proposal would consist of
I'll do a PR later on addressing this :) |
@vorixo Did you open the PR? |
Add/RemoveLooseGameplayTag
on the target's ASC, which might be convenient for gameplay