How to signal outcome to ability task wait conform cancel?

I’m talking about UAbilityTask_WaitConfirmCancel but the forum software doesn’t let me post that in the title (too long a word.)

How does the interaction signal “Confirm” or “Cancel” when using this waiting ability task?
Is there an example of this somewhere I’ve missed?

I’m slowly making my way through the code on this subject.
(This is a background task, luckily, given the dearth of publicly available information …)

Currently investigating: AGameplayAbilityTargetActor_ActorPlacement
There are a whole two (2) hits on this class name on Google!
One is the unreal docs, which just list the members (thanks! It’s not like I have the source right here! :smiley: )
The other is the GameplayAbilityShooter subclassing it, which at least shows an actual use.

Maybe someone else will find this on Google when looking for it. Here’s hoping!

Anyway, the built-in asynchronous positioning features in the Gameplay Abilities System works as such:

  1. You need to bind two input keys to “Confirm” and “Cancel” actions
  2. Those should call YourPawn->AbilitySystemComponent->Target{Confirm,Cancel} which are pre-existing functions
  3. Your GameplayAbility, in EventActivateAbility, needs to spawn a sub-task using WaitTargetData
  4. This sub-task should be a GameplayAbilityTargetActor_ActorPlacement, configured with the appropriate size/assets

Note that this will use your player aim direction for placement, and the sphere (or capsule) of the size you configure, for placement. If you need fancier placement go/no-go, such as “needs flat ground” or “box collisions” or whatever, you’ll need to subclass this class, using C++.

Anyway, with this wired up, it works pretty well off the shelf. Just finding the right combination of pieces for this task was a PITA. Here’s the main part that might unlock the rest of the flow for someone else in a similar position:

1 Like

Seems like you’ve already figured it out. Just wanted to drop a link to the GitHub - tranek/GASDocumentation: My understanding of Unreal Engine 4's GameplayAbilitySystem plug project in case you weren’t aware of it. The section 4.11 covers Targeting and seems to match your solution in terms of cancel/confirm on input. There are also two example games.

Yeah, tranek/GASDocumentation: My understanding of Unreal Engine 4’s GameplayAbilitySystem plugin with a simple multiplayer sample project. is the best documentation I could find! (I think I mentioned this in another thread.)
Whoever Tranek is (@Tranek1997 perhaps?) – thank you!