Wanted
2009-11-26 17:01:39
Ok so I lost my account in the random but I manage to collect the colors for the hat of the forester and the tail tip grey colors, I made these functions. Idk if this helps but maybe you can use it to fix forester.scar
I still have accounts in Blonde Molly, maze, and beekeeper.
program New;
//{.Include SRL\SRL\Misc\SMART.SCAR}
{.Include SRL\SRL.SCAR}
function TalkToFreakyForester: Boolean;
var
TPAA: T2DPointArray;
TPA: TPointArray;
TF: TPoint;
I: LongInt;
begin
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(0.02, 0.11);
FindColorsTolerance(TPA, 1262472, MSX1, MSY1, MSX2, MSY2, 7);
ColorToleranceSpeed(1);
SetColorSpeed2Modifiers(0.2, 0.2);
TPAA := TPAToATPAEx(TPA, 20, 20);
SortATPASize(TPAA, True);
for I := 0 to High(TPAA) do
begin
TF := MiddleTPA(TPAA[I]);
MMouse(TF.X, TF.Y, 1, 1);
Wait(200 + Random(50));
if (IsUpTextMultiCustom(['eaky', 'orest', 'ster'])) then
begin
Result := True;
GetMousePos(TF.X, TF.Y);
Mouse(TF.X, TF.Y, 0, 0, True);
Wait(200 + Random(250));
Flag;
Wait(200 + Random(250));
Exit;
end;
end;
WriteLn('Could not find Freaky Forester!');
end;
function GetTask: Integer;
var
Tails: TStringArray;
I: Byte;
begin
Tails := ['one', 'two', 'three', 'four'];
for I := 0 to 3 do
if (FindNPCChatText(Tails[I], Nothing)) then
if (I > 0) then
Break;
if (I < 4) then
begin
WriteLn('Kill a ' + Tails[I] + '-tailed pheasant');
Result := I + 1;
Exit;
end;
WriteLn('GetTask failed!');
end;
function KillPheasant(Tails: Byte): Boolean;
var
TPAA: T2DPointArray;
TPA: TPointArray;
I, MS: Integer;
KP: TPoint;
begin
MS := MouseSpeed;
MouseSpeed := 45;
FindColorsSpiralTolerance(MSCX, MSCY, TPA, 9674666, MSX1, MSY1, MSX2, MSY2, 0);
TPAA := TPAToATPAEx(TPA, 25, 25);
SortATPASize(TPAA, ((Tails = 3) or (Tails = 4)));
for I := 0 to High(TPAA) do
begin
if ((Tails = 2) or (Tails = 3)) then
if (Length(TPAA[I]) < 3) then
Continue;
if (Tails = 3) then
if (Length(TPAA[I]) > 6) then
Continue;
KP := MiddleTPA(TPAA[I]);
MMouse(KP.X, KP.Y, 1, 1);
Wait(200 + Random(50));
if (IsUpTextMultiCustom(['easant', 'heas'])) then
begin
Result := True;
GetMousePos(KP.X, KP.Y);
Mouse(KP.X, KP.Y, 0, 0, True);
Wait(200 + Random(250));
Flag;
Wait(200 + Random(250));
MouseSpeed := MS;
Exit;
end;
end;
MouseSpeed := MS;
end;
var
T: LongInt;
begin
SetUpSRL;
ActivateClient;
Wait(1000);
//TalkToFreakyForester;
//Wait(750 + Random(500));
//WriteLn(GetTask);
T := GetSystemTime;
while (((GetSystemTime - T) < 25000) and (not (KillPheasant(3)))) do
Wait(500 + Random(50));
end.I still have accounts in Blonde Molly, maze, and beekeeper.