Need a little help. I've done some changes to the Necro Bot for myself and it's a lot faster now. Problem I'm having is I want to place my guy in higher level mobs and cast my 2 dots and then loop my DD spell until the Mob is dead. From what I've managed to figure out in the code it would look like it should work but it doesn't. Can someone help me with this.
Do until (getTargetId = 0 or getTargetHealth = 0)
'Lets be sure we are facing target...
faceMob getTarget
Log.DebugLog ("Cast HOTKEY_ATTACK_SPELL_1...")
VGSendText HOTKEY_ATTACK_SPELL_1
Sleep SLEEP_ATTACK_SPELL_1
exit do
Loop
Is the snipit of code. Thank you for any help.
Here is the whole function.
Code: Select all
function KillCurrentTarget()
'Send in Pet
Log.DebugLog "Sending in Pet..."
VGSendText("-")
do until (Target.HP < 95)
Sleep 1000
Loop
Log.DebugLog "Facing Mob..." & Target.HP
faceMob getTarget
Log.DebugLog "Moving to Target"
'MoveToMob getTarget
Log.DebugLog "Wait 2 secs for aggro..."
Sleep 2000
'Lets be sure we are facing target...
faceMob getTarget
Log.DebugLog ("Cast HOTKEY_ATTACK_SPELL_2...")
VGSendText HOTKEY_ATTACK_SPELL_2
Sleep SLEEP_ATTACK_SPELL_2
Do until (getTargetId = 0 or getTargetHealth = 0)
'Lets be sure we are facing target...
faceMob getTarget
Log.DebugLog ("Cast HOTKEY_ATTACK_SPELL_1...")
VGSendText HOTKEY_ATTACK_SPELL_1
Sleep SLEEP_ATTACK_SPELL_1
exit do
Loop
'Lets be sure we are facing target...
'faceMob getTarget
'Log.DebugLog ("Cast HOTKEY_ATTACK_SPELL_1...")
'VGSendText HOTKEY_ATTACK_SPELL_1
'Sleep SLEEP_ATTACK_SPELL_1
'Lets be sure we are facing target...
'MoveToMob getTarget
'Log.DebugLog ("Auto Attack ON...")
'VGSendText(HOTKEY_AUTO_ATTACK)
'Sleep 1000
'Do until (getTargetId = 0 or getTargetHealth = 0)
if (getPlayerHealth = 0) then
Log.DebugLog "You have died!~"
RunCounter = MAX_RUNS 'this wil stop the script
'exit do
end if
'Loop
end function