Download

GameplayAbilityTargetActor C++ class not returning data

Using the Gameplay Abilities system in 4.13, I’ve managed to use the system to activate an ability, use it to spawn an actor, which itself has an ability which triggers projectile movement and waits for an overlap. The final step is that I need to apply a damage effect to all targets within a radius (AoE explosion).

I’ve almost managed to get the AoE spell to fire, my problem is that I cannot get any targeting data out of the Wait Target Data node. I’ve tried using both the included _Radius class and my own TargetsInRadius class, which immediately confirms results to provide an AoE list of actors. No matter what I feed it, I can’t seem to get this data out of the node.

Here’s what I have in my Ability Blueprint:
e332593cc0f5f54567c8a5e67036cc3c002833ed.png

Heres the modified code in my custom GameplayAbilityTargetActor C++ class to immediately confirm the targeting.



void ATargetsInRadius::StartTargeting(UGameplayAbility* InAbility)
{
	Super::StartTargeting(InAbility);
	SourceActor = InAbility->GetCurrentActorInfo()->AvatarActor.Get();
	ConfirmTargetingAndContinue();
}

void ATargetsInRadius::ConfirmTargetingAndContinue()
{
	//check(ShouldProduceTargetData());
	if (SourceActor)
	{
		FVector Origin = StartLocation.GetTargetingTransform().GetLocation();
		FGameplayAbilityTargetDataHandle Handle = MakeTargetData(PerformOverlap(Origin), Origin);
		TargetDataReadyDelegate.Broadcast(Handle);
	}
}


The rest of the class is identical to the GameplayAbilityTargetActor_Radius class.