Simba Code:
function renzanityFindObj(hue, sat: extended; W, H, colour, tolerance, clickType: integer; mouseOverText, chooseOptions: array of string): boolean;
var
i, x, y: integer;
TPA: TPointArray;
ATPA: T2DPointArray;
begin
if not isLoggedIn() then
exit(false);
findColorsSpiralTolerance(x, y, TPA, colour, mainScreen.getBounds(), tolerance, colorSetting(2, hue, sat));
if (length(TPA) < 1) then
exit();
ATPA := TPA.cluster(W, H);
ATPA.filterBetween(0, 5);
ATPA.sortFromSize(25, true);
ATPA.sortFromMidPoint(mainscreen.playerPoint);
for i := 0 to high(ATPA) do
begin
case random(5) of
0..3: missMouse(middleTPA(ATPA[i]), true)
else
mouse(middleTPA(ATPA[i]), MOUSE_MOVE);
end;
if isMouseOverText(mouseOverText, 500) then
begin
fastClick(clickType);
if clickType = MOUSE_LEFT then
exit(true);
if chooseOption.select(chooseOptions) then
exit(true)
else
begin
mouse(mainscreen.getBounds().getGaussPoint(), MOUSE_MOVE);
end;
end;
end;
end;