Simba Code:
Function Click: Boolean;
Var
tmpCTS,i, L,Counter: Integer;
ObjTPA: TPointArray;
ObjATPA: T2DPointArray;
X,Y,DMCount,Moves: Integer;
Begin
Moves:=0;
DMCount:=0;
tmpCTS := GetToleranceSpeed;
SetColorToleranceSpeed(2);
// set sat and hue mod's
SetToleranceSpeed2Modifiers(0.06, 0.41);
// color and tol
FindColorsTolerance(ObjTPA, 3172740, MSX1, MSY1, MSX2, MSY2, 4);
// splits colors into little box like things :)
SplitTPAWrap(ObjTPA, 10, ObjATPA);
SortATPAFromFirstPoint(ObjATPA, Point(MSCX,MSCY));
SetColorToleranceSpeed(tmpCTS);
// sets mod's back to defualt
SetToleranceSpeed2Modifiers(0.02, 0.02);
DMCount:=RandomRange(3,5);
// sets amount of boxes to amount found (objATPA)
L := High(ObjATPA)
MarkTime(Counter);
// repeats for how ever many boxes there are
For i := 0 To L Do
Begin
MiddleTPAEx(ObjATPA[i], X, Y);
Repeat Begin
Moves:=Moves+1;
mmouse(x, y, 5, 5);
Wait(RandomRange(140, 200));
// hovers over area, if the correct uptext is there it clicks and exits
// if not it goes to the next area
If (P07_IsUpTextMultiCustom(['Use','Bank boo', 'Bank booth'])) Then
Begin
clickmouse2(mouse_Left);
Exit;
End;
End; Until (Moves > DMCount) Or (TimeFromMark(Counter) > 5000)
Break;
End;
Result:=False;
End;