; <COMPILER: v1.1.30.01>
#SingleInstance,Force
CoordMode, Mouse, Screen
Menu, tray, NoStandard
Menu, tray, add, Закрыть, Exit
sumka := 65
inv_sum1 := 250
inv_sum2 := 215
gui, font, s9, Arial
Gui, Add, Checkbox, gMySumka, Сумка надета.
Gui, Add, Text, , F5 - перезагрузка`nF9 - выключить паузу`nF8 - включить паузу
Gui, Add, Text, cGreen, F7 - включить бота
Gui, Add, Text, cRed, F2 - выключить бота
Gui, Show, xCenter yCenter w170 h150
return
GuiEscape:
GuiClose:
ExitApp
return
MySumka:
sumka := 185
inv_sum1 := 365
inv_sum2 := 330
return
F5::
Reload
return
F9::
Pause, Off
return
F8::
Pause, On
return
F7::
inv_x1 := round( A_ScreenWidth-300 )
inv_y1 := round( ( A_ScreenHeight/2 )-inv_sum1 )
inv_x2 := round( A_ScreenWidth-250 )
inv_x22 := 20
inv_y2 := round( ( A_ScreenHeight/2 )-inv_sum2 )
udo_x := round( A_ScreenWidth-425 )
udo_y := round( ( A_ScreenHeight/2 )-sumka )
mouse_x := round( ( A_ScreenWidth/2 )+92 )
mouse_y := round( ( A_ScreenHeight/2 )+( A_ScreenHeight/3 )+8 )
ready_x1 := round( ( A_ScreenWidth/2 )-315 )
ready_y1 := round( A_ScreenHeight-63 )
ready_x2 := round( ( A_ScreenWidth/2 )-305 )
ready_y2 := round( A_ScreenHeight-59 )
Loop {
Label1:
sleep, 500
BlockInput, SendAndMouse
SendInput, {sc17}
BlockInput, Default
sleep 1500
ImageSearch,,, inv_x1, inv_y1, inv_x2-inv_x22, inv_y2, *TransBlack *50 10.png
if ( ErrorLevel = "0" ) {
sleep, 500
SoundBeep, 400, 800
SoundBeep, 400, 800
return
}
ImageSearch,,, inv_x1, inv_y1, inv_x2, inv_y2, *TransBlack *50 99.png
if ( ErrorLevel = "0" ) {
sleep, 500
SoundBeep, 400, 800
SoundBeep, 400, 800
return
}
ImageSearch,,, inv_x1, inv_y1, inv_x2, inv_y2, *TransBlack *50 98.png
if ( ErrorLevel = "0" ) {
sleep, 500
SoundBeep, 400, 800
SoundBeep, 400, 800
return
}
ImageSearch,,, inv_x1, inv_y1, inv_x2, inv_y2, *TransBlack *50 97.png
if ( ErrorLevel = "0" ) {
sleep, 500
SoundBeep, 400, 800
SoundBeep, 400, 800
return
}
BlockInput, SendAndMouse
Click right %udo_x%, %udo_y%
BlockInput, Default
sleep, 1000
ImageSearch, FoundX, FoundY, 0, 0, A_ScreenWidth, A_ScreenHeight, *50 robot.png
if ( ErrorLevel = "0" ) {
SoundBeep, 1200
SoundBeep, 900
SoundBeep, 1200
SoundBeep, 890
SoundBeep, 700
SoundBeep, 890
SoundBeep, 600
}
sleep, 5000
Label2:
PixelGetColor, color, mouse_x, mouse_y, RGB
Var1 = %color%
if ( Var1 = 0xFF0000 or Var1 = 0xFA0000 or Var1 = 0xFB0000 or Var1 = 0xF90000 or Var1 = 0xFE0000 or Var1 = 0xFD0000 ) {
Loop 2 {
Send {Click}
sleep 50
}
Goto, Label2
}
else {
PixelSearch, x, y, ready_x1, ready_y1, ready_x2, ready_y2, 0x97FA04, 3, Fast RGB
if ( ErrorLevel = "0" ) {
Goto, Label1
}
else {
Goto, Label2
}
}
}
return
F2::
Exit:
ExitApp
return