# "On Take Any Damage" and "Get Distance To" not updating properly

**URL:** <https://forums.unrealengine.com/t/on-take-any-damage-and-get-distance-to-not-updating-properly/307246>\
**Category:** World Creation\
**Tags:** distance, unreal-engine, UE4, question, Blueprint\
**Created:** [February 17, 2015, 8:34pm UTC](https://forums.unrealengine.com/t/on-take-any-damage-and-get-distance-to-not-updating-properly/307246 "2015-02-17T20:34:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_260926f1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_260926f1](https://forums.unrealengine.com/u/anonymous_user_260926f1)\
**Post date:** [February 17, 2015, 8:34pm UTC](https://forums.unrealengine.com/t/on-take-any-damage-and-get-distance-to-not-updating-properly/307246/1 "2015-02-17T20:34:51Z")

</div>

I’d like to check the distance between a StaticMesh and the player when the player shoots the StaticMesh. I’m using an OnTakeAnyDamage event from the mesh and using Get Distance To to return the distance between the mesh and the Instigator. This does return a distance, but it doesn’t seem correct, and doesn’t update/change when the player moves around.

 ![30263-ue4_takedamage_distance.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/7/d/87dde65d137c4d327140c868be0aed9a8e36175e.png)

When I use OnActorHit instead of Damage, the distance does indeed update properly. Anyone have any ideas?
