Making an RTS battle system - Referencing objects problem

I’m trying to make a real time strategy fight system, for example, the one you find in Age of Empires. I’m having some trouble with referencing objects. I have two objects and they become close enough to fight, but they will not damage each other properly in some cases. I have included my file with this post. Any help is appreciated. :smiley:
Fightsystem1.gdg (90.6 KB)