-
Member
Seeking advice for combat routine
Hi everyone,
I thought this would be useful for other people new to memory editing like myself. I have reached a point where I think I know how to read the fields I need in memory (health/power/position/facing/casting/calling specific functions from my thread etc.). I now need to decide how to structure my combat routine bot. I'm not looking to make a fully autonomous bot, just a sophisticated combat routine with the following requirements:
1. Movement controlled entirely by the user.
2. For healing - auto select the best target to heal, for damage - mainly focus on target chosen by user and on rare occasions interrupt a cast on a nearby unit.
3. Maintain a list of friendly/attackable list of units in range that can be iterated through.
4. Being able to cast heals/abilities, taking into consideration range/cooldowns etc.
5. Detect and AOE scenario and cast an AOE ability in optimal position when needed (should handle clicking AOE on its own).
6. I do not want to unlock lua to cast abilities, I want to use a keyboard/mouse (I've already developed this) that can be commanded to press a button or move a mouse.
Currently, I can inject my DLL into wow and read memory that I need and run lua functions that simply read values like spell cooldowns, health, power, dead or ghost etc. Those function calls work just fine, but as soon as you get into functions that actually alter the game internal state a different, more advanced, approach is required. In a specific example, I tried calling the CGGameUI::OnTerrainClick (to place AOE at feet of a unit), I'm seeing random crashes here and there and at other times it just works, I believe it is due to calling the function from a remote thread asynchronously - base on a quick search probably need to call this from hooked EndScene to work 100%. I want to ask everyone's experience in what's the simplest and most effective way to approach this given my requirements above.
Thanks in advance.
-
Active Member
Originally Posted by
goblin2kx
Hi everyone,
I thought this would be useful for other people new to memory editing like myself. I have reached a point where I think I know how to read the fields I need in memory (health/power/position/facing/casting/calling specific functions from my thread etc.). I now need to decide how to structure my combat routine bot. I'm not looking to make a fully autonomous bot, just a sophisticated combat routine with the following requirements:
1. Movement controlled entirely by the user.
2. For healing - auto select the best target to heal, for damage - mainly focus on target chosen by user and on rare occasions interrupt a cast on a nearby unit.
3. Maintain a list of friendly/attackable list of units in range that can be iterated through.
4. Being able to cast heals/abilities, taking into consideration range/cooldowns etc.
5. Detect and AOE scenario and cast an AOE ability in optimal position when needed (should handle clicking AOE on its own).
6. I do not want to unlock lua to cast abilities, I want to use a keyboard/mouse (I've already developed this) that can be commanded to press a button or move a mouse.
Currently, I can inject my DLL into wow and read memory that I need and run lua functions that simply read values like spell cooldowns, health, power, dead or ghost etc. Those function calls work just fine, but as soon as you get into functions that actually alter the game internal state a different, more advanced, approach is required. In a specific example, I tried calling the CGGameUI::OnTerrainClick (to place AOE at feet of a unit), I'm seeing random crashes here and there and at other times it just works, I believe it is due to calling the function from a remote thread asynchronously - base on a quick search probably need to call this from hooked EndScene to work 100%. I want to ask everyone's experience in what's the simplest and most effective way to approach this given my requirements above.
Thanks in advance.
Calling these internal functions in the context of a thread you've forcibly created yourself certainly will not work. There also isn't a guarantee they work reliably from a rendering thread either! That's all I'm willing to share publicly, good luck!
-
Post Thanks / Like - 1 Thanks
hackerlol (1 members gave Thanks to scimmy for this useful post)