Hey everyone,
I created this function for my Tutorial Island Runner
I tested this 20 times, and it always worked.
Can someone please test it again?
Please post the result here
Thanks a lot,
PvH

Here it is:
SCAR Code:
program test;
{.include SRL/SRL.scar}

function FindUndergroundColor: Integer;
var
  GC, a, l, TestColor, Red, Green, Blue: integer;
var
  P:array of Tpoint;
begin
  wait(2000);
  GC := 4350011;
  Flag;
  FindColorsSpiralTolerance(MMCX, MMCY, P, GC, MMX1, MMY1, MMX2, MMY2, 140);
  l:=GetArrayLength(P);
  for a:= 0 to l-1 do
  begin
    if rs_OnMinimap(P[a].x,P[a].y) then
    begin
      TestColor := GetColor(P[a].x,P[a].y);
      if SimilarColors(TestColor,GC,140) then
      begin
        ColorToRGB(TestColor, Red, Green, Blue);
        if InRange(Red - Green, 5, 33) then if Red <= 120 then
          if InRange(Green - Blue, 17, 58) then
            if InRange(Red - Blue, 30, 75) then if Blue <= 45 then
              if GetColor(P[a].x + 5, P[a].y + 5) = TestColor then
                if GetColor(P[a].x + 3, P[a].y + 3) = TestColor then
                  if GetColor(P[a].x, P[a].y + 5) = TestColor then
                    if GetColor(P[a].x + 5, P[a].y) = TestColor then
                      if GetColor(P[a].x, P[a].y + 3) = TestColor then
                        if GetColor(P[a].x + 3, P[a].y) = TestColor then
                          if GetColor(P[a].x + 5, P[a].y + 3) = TestColor then
                            if GetColor(P[a].x + 3, P[a].y + 5) = TestColor then
                            begin
                              Result := TestColor;
                              WriteLn('UnderGroundColor = ' + IntToStr(TestColor));
                              Exit;
                            end;
      end;
    end;
  end;
  WriteLn('Could not find UnderGroundColor!');
  Result := 0;
end;

begin
  SetupSRL;
  ActivateClient;
  FindUndergroundColor;
end.