TakeDamage() function always returns base damage after recieving radial damage

Been trying to convert my blueprint code to c++ and i reached a problem with receiving of radial damage . It worked perfectly in blueprint where i get the desired damage based on the distance between impact point . But in code i used the function

TakeDamage(float DamageAmount, struct FDamageEvent const& DamageEvent, class AController EventInstigator, class AActor DamageCauser)**

It always returns the base damage of the radial impact (in my case its 5000) . Im not sure whats wrong on my side . Going through the docs i noticed the below function

InternalTakeRadialDamage(float Damage,FRadialDamageEvent const & RadialDa…)

i overridden the above function but i dont get any response . I only receive the damage within the TakeDamage always returning the exact base damage (5000) . Can somebody tell me how to get radial damage properly ? much appreciated .

Thanks

I had used the below condition to make sure the damage event i recieve is infact a radial damage . The condition returns true even though the damage is always the base damage .

if (DamageEvent.IsOfType(FRadialDamageEvent::ClassID))

I swept this problem under the rug by simply creating a c++ function getDamage() accessible through blueprint and just connecting to the EventRadialDamage node . Thanks for the reply . :slight_smile:

Well, looking at the implementation of TakeDamage, internally it calls InternalTakeRadialDamage only if

DamageEvent.IsOfType(FRadialDamageEvent::ClassID)

So if you’re not getting a response from the internal function I’d suspect that the damage event is not correctly specified. I’d suggest overriding your actor’s TakeDamage function with the full version of Actor and setting breakpoints to see where the code branches off.