Gucci
2012-03-27 02:45:39
Hi everyone I'm working on a arctic pine script and was using this function to find the pines :
But using this the mouse just keeps flying around to all the pine trees without clicking on then even though I have chopping set like this:
Any help would be appreciated
function FindPine(x, y: Integer): Boolean;
var
CTS, I: Integer;
TPA: TPointArray;
ATPA: Array of TPointArray;
begin
CTS := GetColorToleranceSpeed;
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(0.20, 0.16);
FindColorsSpiralTolerance(MSCX, MSCY, TPA, PineColor, MSX1, MSY1, MSX2, MSY2, 25);
ColorToleranceSpeed(CTS);
ATPA := TPAToATPAEx(TPA, 15, 15);
For I := 0 to High(ATPA) do
begin
MiddleTPAEx(ATPA[i], x, y);
MMouse(x, y, 2, 2);
If(IsUpTextMultiCustom(['hop, ine, rctic'])) then
begin
Result := True;
GetMousePos(x, y);
Break;
end;
end;
end;But using this the mouse just keeps flying around to all the pine trees without clicking on then even though I have chopping set like this:
if FindPine(x, y) then
begin
Writeln('Tree Has Been Found');
Wait(10+ Random(20));
MMouse(x, y, 4, 4);
if WaitUpText('rctic', 500) then
Wait(10+ Random(45));
Mouse(x, y, 0, 0, True);
end; Any help would be appreciated