Kibor Bot Autoclicker » Kibor - Integrated development environment for bots » Issues and problem solving » can not make script

Страниц (1): [1]
 

1. konmason - 04 Декабря, 2017 - 13:35:02 - перейти к сообщению
The meaning of how I understand the situation - to search for the desired image on the field and if found, then handle the event by pressing the mouse. and So in an infinite loop.

 Цитата:
int ferat[10][5];
int PosX_0[1], PosY_0[1];
int color, xe, ye;
getdisplay(color, xe, ye);
loadimage (#ferat[0][0], "C:\terret\mit.bmp");
e: if (findimage(1, #ferat[0][0], 0, #PosX_0[0], #PosY_0[0], 0, 0, xe, ye, -1)==0)
{
sleep(50);
}
else
{
mousedbl(LEFT, PosX_0[0]+imagewidth(#honey[0][0])/2, PosY_0[0]+imageheight(#honey[0][0])/2, 1, wind);
mouse(LEFT, PosX_0[0]+imagewidth(#honey[0][0])/2, PosY_0[0]+imageheight(#honey[0][0])/2);
}
goto e;

w=window ("It yer", "as23Qe", -1)

2. Kibor - 04 Декабря, 2017 - 13:52:38 - перейти к сообщению
CODE:
loop()
{
if (findimage(1, #ferat[0][0], 0, #PosX_0[0], #PosY_0[0], 0, 0, xe, ye, -1)==1)
{
mouse(LEFT, PosX_0[0], PosY_0[0]);
}
sleep(10);//pause that would not load the processor
}

Powered by ExBB FM 1.0 Final