[GAS] ApplyGameplayEffectToTarget doesn't trigger cues properly?

Hello, everyone I have created Gameplay Ability in the Blue Print for that gameplay ability after the Event Activate Ability I am calling two Nodes first being HasAuhtority() and if true i am executing ApplyGameplayEffectToTarget with GE.


On the GE BP I have created Gameplay Cues with tag GameplayCue.Character.asd I have also created GameplayCueNotify_BurstLatent to response to that tag, but the problem I am facing is that the this Cue is triggered for everyone else except for the client who called the Gameplay Ability.

The replication mode is set to SetReplicationMode(EGameplayEffectReplicationMode::Mixed);. Has anyone faced simililar issue before and how did you solved it. Thanks in advance.

1 Like

have you tried to remove HasAuthority() check? I’m not sure what it returns on the client in your case, but if it’s false then it’s may be a possible reason, something like: server get a call and execute cue, simulated get a replicated cue from a server, authonomous get no replicated cue due to the fact that cue code was supposed to be already executed here (and in fact it wasn’t, since it was gated).

1 Like

Thank you for your reply. Indeed I’ve tried to remove the HasAuthority() and its working as intended, but the Server has to have authority over the GE executions as of my knowledge, and then with the mixed mode the GE is replicated to owning clients and the cues should be replicated to all clients? Is that correct or I am missing something ?

With HasAuthority print nodes placed in the GameplayCueNotify_BurstLatent in onburst event node it prints:
Client 1:Hello
The client who is executing the GA is Client 2 but he never prints the message from the GCN

Without HasAuthority prints (And that should be the correct version that I am after:
Client 1:Hello
Client 2:Hello

if I test the same thing with 3 clients it will be printed as follow
With HasAuthority print nodes placed in the GameplayCueNotify_BurstLatent in onburst event node it prints:
Client 1:Hello
The client who is executing the GA is Client 2 but he never prints the message from the GCN
Client 3:Hello

Without HasAuthority prints:
Client 1:Hello
Client 2:Hello
Client 3:Hello

It was just a bug with the GE, I changed the Duration Policy on the GE from instant to Has Duration and I set the Period number to be other then 0 (I Changed it to 5) and it was working as intended then switched back to instant and all worked as I wanted.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.