I am having trouble with this function, sometimes at the fallador east bank, the findfallyroadcolor returns 0....any ideas?
I am having trouble with this function, sometimes at the fallador east bank, the findfallyroadcolor returns 0....any ideas?
Not finding the road color maybe? Try making your own auto color.
autocolors don't work, they havent for forever. I've made a few versions of temp fixes, If you would like my most recent let me know.
“Ignorance, the root and the stem of every evil.”
AutoColors don't work? why haven't they been fixed?
And yes I would love your version, assuming its working of course...
SCAR Code:const
SRLAC_RoadColour = 6579821;
SRLAC_VarrockRoadColour = 8291719;
SRLAC_FallyRoadColour = 7831173;
SRLAC_LumbyRoadColour = 8225677;
SRLAC_DirtRoadColour = 1853272;
SRLAC_WaterColour = 10850700;
SRLAC_RockColour = 5789528;
SRLAC_SandColour = 0;
SRLAC_BankerColour = 1179390;
Procedure SortColors(var Colors: tIntegerArray; col: Integer);
var
tempB: tIntegerArray;
Tol: ShortInt;
I: Integer;
timer, L: LongInt;
begin
timer := getsystemtime;
tempB := Colors;
SetArrayLength(Colors, 0);
Tol := 0;
while Length(Colors) < (Length(tempB)/2 or 5) do
begin
if Getsystemtime-timer > 100 then Break;
for i := 0 to High(tempB) do
begin
if SimilarColors(tempB[i], col, Tol) then
begin
L := GetArrayLength(Colors);
SetArrayLength(Colors, L+1);
Colors[L] := tempB[i];
end;
if Tol > 10 then Break;
Inc(Tol);
end;
end;
end;
Function AutoColorMM(const color: Integer): Integer;
var
TPA: tPointArray;
List: tIntegerArray;
I: Integer;
begin
for i := 0 to 20 do
begin
FindColorsTolerance(TPA, color, MMx1, MMy1, MMx2, MMy2, 5+i);
if Length(TPA) > 0 then Break;
end;
if Length(TPA) <= 0 then Exit;
List := getColors(TPA);
sortColors(List, color);
if Length(List) <= 0 then Exit;
result := List[0];
end;
Function FindNewVarrockRoadColor: Integer;
begin
Result := AutoColorMM(SRLAC_VarrockRoadColour);
end;
for falador simply change AutoColorMM(SRLAC_VarrockRoadColour) to AutoColorMM(SRLAC_FallyRoadColor)![]()
“Ignorance, the root and the stem of every evil.”
There are currently 1 users browsing this thread. (0 members and 1 guests)