# How can I apply Radial Damage?

**URL:** <https://forums.unrealengine.com/t/how-can-i-apply-radial-damage/280582>\
**Category:** Community & Industry Discussion\
**Tags:** radial-damage, damage, unreal-engine, pawn, question\
**Created:** [April 14, 2014, 4:45pm UTC](https://forums.unrealengine.com/t/how-can-i-apply-radial-damage/280582 "2014-04-14T16:45:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_7587ca9c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_7587ca9c](https://forums.unrealengine.com/u/anonymous_user_7587ca9c)\
**Post date:** [April 14, 2014, 4:45pm UTC](https://forums.unrealengine.com/t/how-can-i-apply-radial-damage/280582/1 "2014-04-14T16:45:41Z")

</div>

Hello everyone.  
Im trying to make a projectile damage. Seems like ApplyRadialDamage not working for me.  
I also tried to do it using blueprints, it make’s same result.  
I checked in collision settings to block visibility trace.

Can anyone help?

Thanks for attention.

Code:

```
if (WeaponConfig.ExplosionDamage > 0 && WeaponConfig.ExplosionRadius > 0 && WeaponConfig.DamageType)
	{
		UGameplayStatics::ApplyRadialDamage(this, WeaponConfig.ExplosionDamage, NudgedImpactLocation, WeaponConfig.ExplosionRadius, WeaponConfig.DamageType, TArray<AActor*>(), this, MyController.Get(), true);
	}

```

---

<div class="post-metadata">

**Author:** ![iscaru1988](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@iscaru1988](https://forums.unrealengine.com/u/iscaru1988)\
**Post date:** [July 18, 2014, 11:25am UTC](https://forums.unrealengine.com/t/how-can-i-apply-radial-damage/280582/2 "2014-07-18T11:25:38Z")

</div>

I have the same issue.  
Did you found any solution?

---

<div class="post-metadata">

**Author:** ![DrHobo](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DrHobo](https://forums.unrealengine.com/u/DrHobo)\
**Post date:** [August 13, 2014, 4:23pm UTC](https://forums.unrealengine.com/t/how-can-i-apply-radial-damage/280582/3 "2014-08-13T16:23:34Z")

</div>

My solution to this is to iterate amongst all actors of a given class then calculate the distance for each actor that matches your criteria and apply damage here.

```
float ExplosionRadius = 200.0f;
float ExplosionDamage = 25.0f;

for ( TActorIterator<AMyCharacter> aItr(GetWorld()); aItr; ++aItr )
{
	float distance = GetDistanceTo(*aItr);

	if (distance <= ExplosionRadius)
	{
		UGameplayStatics::ApplyDamage(*aItr, ExplosionDamage, 
		GetInstigatorController(), this, UDamageType::StaticClass());
	}
}

```

Don’t forget to configure your target actor class to **take damage** as well 🙂
