Hey I have a really cool Warcraft program I'm trying to write. I am a professional programmer, but I don't know a whole lot about game hacking, perhaps you can point me in the right direction. I know about basic hacking stuff (changing gold amount, unit visibility, etc.), but this program is intended to only read the game state.

Essentially I need a list of tuples for each unit (visible is fine) in the game with the following info

(Location, Team, HP, Unit Type);

How can I build up such a list? Is it unfeasible? I'm really wondering if someone has put the time and info into building up such a function already. Any help is appreciated.

I dumbed down version of what I am trying to do would be to have a program that automatically attacks the unit with the lowest HP that is in range of your hero. All I need is the data to allow for this type of action and I am golden