CCKK@
maybe color hex for red in ur computer is different
what did the debug say about the health hex?
maybe color hex for red in ur computer is different
what did the debug say about the health hex?
#Persistent
IniRead, Charactername, %A_ProgramFiles%\path.ini, section1, Charactername
if CharacterName=Error
{
Charactername=0x53D4CC
IniWrite, %Charactername%, %A_ProgramFiles%\path.ini, section1, Charactername
}
send {Ctrl up}
#Persistent
Menu, Tray, Icon, Shell32.dll, 44
Gui, +toolwindow
Gui, Add, Text,x10 y12 w80 h20, Log off after:
Gui, Add, Edit, x80 y10 w28 h20 vtimer,60
Gui, Add, Text,x110 y12 w80 h20, mins
Gui, Add, Text,x10 y32 w200 h20, Domain: -+
Gui, Add, Text,x10 y52 w200 h20, Range: -+
Gui, Add, Edit, x80 y30 w50 h20 vx1x,500
Gui, Add, Edit, x80 y50 w50 h20 vy1y,500
Gui, Add, Text,x10 y75 w200 h20, CharNameAddress:
Gui, Add, Edit, x10 y90 w70 h20 vCharactername,%Charactername%
Gui, Add, Button, x10 y122 w80 h20 vButton gStart, >Ok<
Gui, Show, x1 y1 h150 w150, CO Archer
return
GuiClose:
ExitApp
Gui, Show
return
Start:
Gui, Submit, Hide
choosepath=1
pathselect=1
timer *= 60000
StartTime := A_TickCount + timer
difcount=0
WinGet,id, ID,[Co
WinActivate, [Con
Process, Exist,Conquer.exe
pid = %ErrorLevel%
ProcessHandle := DllCall("OpenProcess", "int", 2035711, "char", 0, "UInt", PID, "UInt")
InputBox, name, Enter Character Name for memory address checking, , , 380,100
counter=0
StringSplit, nameArray, name
Loop, 4
{
counter++
this_name := nameArray%counter%
Transform, this_name2, asc, %this_name%
SetFormat, integer, hex
this_name2 += 0
StringReplace, this_name2, this_name2, 0x, , All
namehex=%this_name2%%namehex%
SetFormat, integer, d
}
namehex=0x%namehex%
SetFormat, integer, hex
addressS=%Charactername%
VarSetCapacity(outputA, 4)
DllCall("ReadProcessMemory", "UInt", ProcessHandle, "UInt", addressS, "Uint*", OutputA, "Uint", 4, "Uint *", 0)
if OutputA != %namehex%
{
msgbox, Wrong memory address`nPlease contact me in ELSE thread. `n%OutputA% -%namehex%
exitapp
}
SetFormat, integer, hex
adxxx:=Charactername + 48
adyyy:=adxxx + 4
WinActivate, ahk_id %id%
settimer, Timercheck, 5000
settimer, readXY, 800
VarSetCapacity(orgX, 4)
VarSetCapacity(orgY, 4)
DllCall("ReadProcessMemory", "UInt", ProcessHandle, "UInt", adxxx, "Uint*", orgX, "Uint", 4, "Uint *", 0)
DllCall("ReadProcessMemory", "UInt", ProcessHandle, "UInt", adyyy, "Uint*", orgY, "Uint", 4, "Uint *", 0)
SetFormat, integer, d
lowerboundX := orgX - x1x
lowerboundY := orgY - y1y
UpperboundX := orgX + x1x
UpperboundY := orgY + y1y
lowerboundXa := lowerboundX
lowerboundYa := lowerboundY
UpperboundXa := UpperboundX
UpperboundYa := UpperboundY
IniWrite, %Charactername%, %A_ProgramFiles%\path.ini, section1, Charactername
difx := ceil(x1x / 10)
dify := ceil(y1y / 10)
sleep 1000
loop
{
gosub, function
}
return
return
;--------------------------------------function-------------------
function:
if pathselect = 1
{
if yyy < %lowerboundY%
{
choosepath = 2
pathselect = 2
}
}
else if pathselect = 2
{
if xxx > %UpperboundX%
{
choosepath = 3
pathselect = 3
}
}
else if pathselect = 3
{
if yyy > %UpperboundY%
{
choosepath = 4
pathselect = 4
}
}
else if pathselect = 4
{
if xxx < %lowerboundX%
{
choosepath = 1
pathselect = 1
lowerboundX += difx
lowerboundY += dify
UpperboundX -= difx
UpperboundY -= dify
difcount++
if difcount > 8
{
difcount=0
lowerboundX := lowerboundXa
lowerboundY := lowerboundYa
UpperboundX := UpperboundXa
UpperboundY := UpperboundYa
}
}
}
if choosepath = 1
{
ControlClick, x513 y104,ahk_id %id%,,left
sleep 200
X=513
Y=104
gosub, jump
ControlClick, x513 y304,ahk_id %id%,,right
sleep 1000
}
else if choosepath = 2
{
ControlClick, x893 y384,ahk_id %id%,,Left
sleep 200
X=893
Y=384
gosub, jump
ControlClick, x593 y384,ahk_id %id%,,right
sleep 1000
}
else if choosepath = 3
{
ControlClick, x513 y604,ahk_id %id%,,Left
sleep 200
X=513
Y=664
gosub, jump
ControlClick, x513 y464,ahk_id %id%,,right
sleep 1000
}
else if choosepath = 4
{
ControlClick, x133 y384,ahk_id %id%,,Left
sleep 200
X=133
Y=384
gosub, jump
ControlClick, x433 y384,ahk_id %id%,,right
sleep 1000
}
return
return
;--------------------------------------TimerCheck------------------
Timercheck:
ControlClick, x110 y740,ahk_id %id%,,RIGHT
End := A_TickCount
if End>=%StartTime%
{
winkill, ahk_id %id%
sleep 500
send {Ctrl up}
msgbox, DC timer activate!
reload
return
}
return
return
;--------------------------------------Memory check---------------
readXY:
VarSetCapacity(xxx, 4)
VarSetCapacity(yyy, 4)
DllCall("ReadProcessMemory", "UInt", ProcessHandle, "UInt", adxxx, "Uint*", xxx, "Uint", 4, "Uint *", 0)
DllCall("ReadProcessMemory", "UInt", ProcessHandle, "UInt", adyyy, "Uint*", yyy, "Uint", 4, "Uint *", 0)
return
return
;--------------------------------------Postmessage Jump----------
jump:
hwnd := ControlFromPoint(X, Y, "ahk_id " id,"", cX, cY)
PostMessage, 0x201, 0x8 | 0x1, cX & 0xFFFF | (cY & 0xFFFF) << 16,, ahk_id %hwnd%
PostMessage, 0x202, 0x8 , cX & 0xFFFF | (cY & 0xFFFF) << 16,, ahk_id %hwnd%
return
return
ControlFromPoint(X, Y, WinTitle="", WinText="", ByRef cX="", ByRef cY="", ExcludeTitle="", ExcludeText="")
{
if !(hwnd := WinExist(WinTitle, WinText, ExcludeTitle, ExcludeText))
return false
VarSetCapacity(pt,8)
VarSetCapacity(wi,60), NumPut(60,wi)
DllCall("GetWindowInfo","uint",hwnd,"uint",&wi)
NumPut(X + (w:=NumGet(wi,4,"int")) - (cw:=NumGet(wi,20,"int")), pt,0)
NumPut(Y + (h:=NumGet(wi,8,"int")) - (ch:=NumGet(wi,24,"int")), pt,4)
Loop {
child := DllCall("ChildWindowFromPointEx","uint",hwnd,"int64",NumGet(pt,0,"int64"),"uint",0x5)
if !child or child=hwnd
break
DllCall("MapWindowPoints","uint",hwnd,"uint",child,"uint",&pt,"uint",1)
hwnd := child
}
cX := NumGet(pt,0,"int")
cY := NumGet(pt,4,"int")
return hwnd
}
return
return
;--------------------------------------HotKey---------------------
^r::reload
^q::pause
----
adxxx:=Charactername + 48