Dgby714
02-14-2012, 01:51 AM
program MatsGuildAltarPro;
{$DEFINE SMART}
{$i srl/srl.Simba}
{$i sps/sps.simba}
var
GAltar, Herb, IncenseRight, IncenseLeft, IncenseLeftBack, MountGlory, x, y, Bone: Integer;
AFound: Extended;
TeleTab, InfernAsh, Bones, Door: Integer;
const
BoneType = ('bone');
procedure WalkingtoBank;
var
ToBank: TPointArray;
begin
Wait(700 + Random(200));
SPS_Setup(RUNESCAPE_SURFACE, ['10_6', '10_5', '11_5', '11_6', '9_6', '9_5']);
ToBank := [Point(4186, 2678), Point(4186, 2680), Point(4188, 2682), Point(4191, 2682), Point(4195, 2682), Point(4200, 2682), Point(4205, 2682), Point(4208, 2679), Point(4208, 2675)];
SPS_WalkPath(ToBank);
end;
procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name := '';
Players[0].Pass := '' Players[0].Active := True;
Players[0].Pin := '';
Players[0].Integers[1] := 10000;
end;
procedure SetDTM;
begin
TeleTab := DTMFromString('mwQAAAHic42RgYHBhYmBwA+JAIPYBYlMgtg FiL6gYCD8CqrsOxE+h9AMg/gTFr4D4LhCvWrwISDLhxZIMhAEjERgOAPw+DME=');
InfernAsh := DTMFromString('mrAAAAHic42BgYEgC4nQgzoLiOCCOAOJYIE 4B4iNAvB9KH4BiEPs0EJ8AYl52ViDJhBNLMuAHjAQwDAAA4VsJ gw==');
Bones := DTMFromString('mbQAAAHicY2VgYOBjZGAQB2JJIOYAYmEgzg CKFwJxFhDnAnEqEFfVNzC0dnUzJGdkMMQmJjGUVdcwSALF0TEj FgwGAFmMCc4=');
Herb := DTMFromString('mlwAAAHicY2dgYDjCyMCwFYjPM0LYZ4F4Nx CfBOLpQPkZQDwRiOdB2ZOAeC4Q80TyAUkmrFiSATdgxIOhAADK QAow');
Door := DTMFromString('m6wAAAHic42ZgYJBgZGD4AaQtgbQkEItB+c ZAWh+I9YCYCYj/A8U8QeqA2ApKRwBxJJR2AWI/KO0LxNHBbgyNuWEM1RlBDLGh7gyRgS4MFan+DEUJ3gxlyX4MJU m+YDkQWxKonljMSAJGAgCPcxSX');
MountGlory := DTMFromString('mggAAAHicY2NgYPAFYj8gDgJiDyjtBcSaQK wLxBpQrAfE2kC8qC+X4e8vVYaKRDMwG4YlgXLYMCMODAEA1LwN Eg==');
IncenseRight := DTMFromString('mggAAAHicY2NgYFBjZGDQAmIVINYDYg0gVg TiHqBcAxBXA3EzEE8F4glA/PTJQ4YnWxUYnI1VGTzMNBi+f//G8O7NMwZ+oBw2zIgDQwAAkjMPzw==');
IncenseLeft := DTMFromString('mrAAAAHic42BgYOCEYn4gZgdiISBmZYAALi AWBmIZIJYEYnEgFgBiNqg8ExA/f/6MIdzRgOHbl08MX169ZJg0oY3h3gZ5BnsDZTCWhOrFhRkJYBgA AIBxDzE=');
IncenseLeftBack := DTMFromString('mggAAAHicY2NgYMgG4lwgTgLiBCi7BIgnAH ENEDcAcQsQTwPiSUD84sUzBnsDFQYfK22GYHt9hm9fPzMsXDCf gR8ohw0z4sAQAADQFA+T');
GAltar := DTMFromString('mlwAAAHicY2dgYHgPxBeBmJsRwr4MZb8D0h 1AXAHFk4B4FhBPB+JqIL6xS47h6eN7DK9ePWd4/foVQ4iDPoOnuQbDokWrGCSB8rgwIx4MBQA0YRYm');
end;
procedure FindingDoor;
begin
wait(600 + random(50));
if FindDTMRotated(Door, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(200 + Random(50));
if IsUpText('Door') then
begin
CLickMouse2(True);
end
else
FindingDoor;
Wait(1000 + Random(50));
end
else
FindingDoor;
end;
procedure OpeningDoor;
begin
if FindNormalRandoms then
begin
Logout;
TerminateScript;
end
else
FindingDoor;
Flag;
RadialWalkTolerance(8230043, - 1, 1, 25, - 1, 0, 15);
Flag;
Wait(600 + random(50));
end;
function NPCBankFinder(x, y: Integer): Boolean;
var
CTS, I: Integer;
TPA: TPointArray;
ATPA: array of TPointArray;
begin
CTS := GetColorToleranceSpeed;
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(0.09, 0.69);
FindColorsSpiralTolerance(MSCX, MSCY, TPA, 4007983, MSX1, MSY1, MSX2, MSY2, 14);
ColorToleranceSpeed(CTS);
ATPA := TPAToATPAEx(TPA, 15, 15);
for I := 0 to High(ATPA) do
begin
MiddleTPAEx(ATPA[i], x, y);
MMouse(x, y, 2, 2);
if (IsUpTextMultiCustom(['ank'])) then
begin
Result := True;
GetMousePos(x, y);
Break;
end;
end;
end;
procedure Banking;
var
HerbRun, DoorRun: integer;
begin
if FindNormalRandoms then
begin
Logout;
TerminateScript;
end
else if NPCBankFinder(x, y) then
begin
if IsUpText('ank') then
ClickMouse2(False);
Wait(100 + Random(50));
ChooseOption('Bank Banker');
Wait(4000 + Random(50));
if PinScreen then
InPin(Players[CurrentPlayer].Pin);
if BankScreen then
begin
if FindDTM(Herb, X, Y, MBX1, MBY1, MBX2, MBY2) then
begin
if not FindDTM(Herb, X, Y, MIX1, MIY1, MIX2, MIY2) then
begin
MMouse(X, Y, 5, 5);
repeat
Inc(HerbRun);
ClickMouse2(True);
Wait(300 + Random(50));
until (HerbRun = 2);
end
else
begin
FindDTM(Herb, X, Y, MBX1, MBY1, MBX2, MBY2);
MMouse(X, Y, 5, 5);
ClickMouse2(True);
end;
end;
if BoneType = ('Ash') then
Bone := InfernAsh
else
Bone := Bones;
if FindDTM(Bone, X, Y, MBX1, MBY1, MBX2, MBY2) then
begin
MMouse(X, Y, 5, 5);
ClickMouse2(False);
Wait(100 + Random(50));
ChooseOption('All');
end
else
begin
Writeln('Could not find ' + BoneType);
TerminateScript;
end;
CloseBank;
if FindDTM(TeleTab, X, Y, MIX1, MIY1, MIX2, MIY2) then
begin
MMouse(X, Y, 5, 5);
ClickMouse2(True);
repeat
Wait(50 + Random(50));
until (FindDTMRotated(Door, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound));
end;
end
else
Banking;
end
else
Banking;
end;
procedure Using;
begin
if BoneType = ('Ash') then
Bone := InfernAsh
else
Bone := Bones;
if FindDTM(Bone, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
MMouse(X, y, 5, 5);
Wait(150 + Random(50));
if IsUpText('ashes') or IsUpText('one') then
ClickMouse2(False);
Wait(250 + Random(50));
ChooseOption('Use');
Wait(121 + Random(52));
end;
if FindDTMRotated(GAltar, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(300 + Random(50));
if IsUpText('Altar') then
CLickMouse2(True);
end;
repeat
Wait(50 + Random(50));
until (FindDTM(Bone, x, y, McX1, McY1, McX2, McY2));
end;
procedure Glory;
begin
if FindDTMRotated(MountGlory, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(150 + Random(50));
if IsUpText('let') then
ClickMouse2(True)
else
Glory;
repeat
Wait(50 + Random(50));
until (FindNPCChatText('Edgeville', ClickLeft));
end;
Wait(500 + Random(100));
end;
procedure Giving;
begin
Using;
if BoneType = ('Ash') then
Bone := InfernAsh
else
Bone := Bones;
if FindDTM(Bone, x, y, McX1, McY1, McX2, McY2) then
begin
MMouse(X, y, 5, 5);
Wait(100 + Random(50));
if IsUpText('Offer All') then
ClickMouse2(True);
end
else
Giving;
end;
function IsPraying: Boolean;
begin
if (averagePixelShift(IntToBox(234, 50, 289, 185), 50, 250) > 200) then
begin
Result := True;
Writeln('Pixel Shifting');
end
else
begin
Wait(1000);
if (averagePixelShift(IntToBox(234, 50, 289, 185), 50, 250) > 200) then
Result := True
else
Result := False;
end;
end;
function Praying: Boolean;
begin
if BoneType = ('Ash') then
Bone := InfernAsh
else
Bone := Bones;
if FindDTM(Bone, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
if ClickContinue(True, True) then
begin
Giving;
end;
if IsPraying then
Result := True
end
else
begin
Wait(1000);
if FindDTM(Bone, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
if not isPraying then
Giving;
end
else
Result := False;
end;
end;
procedure IncesRight;
begin
if FindDTMRotated(IncenseRight, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(150 + Random(50));
if IsUpText('Light') then
CLickMouse2(True)
else
IncesRight;
end
else
IncesRight;
end;
procedure InceLeft;
begin
if FindDTMRotated(IncenseLeft, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(150 + Random(50));
if IsUpText('Light') then
CLickMouse2(True)
else
InceLeft;
end
else
begin
Writeln('Failed to Find Incense Left Using Back Up DTM');
if FindDTMRotated(IncenseLeftBack, X, y, MSX1, MSY1, MSX2, MSY2, - Pi / 4, Pi / 4, Pi / 60, aFound) then
begin
MMouse(X, y, 5, 5);
Wait(150 + Random(50));
if IsUpText('Light') then
CLickMouse2(True)
else
InceLeft;
end;
end;
end;
procedure WastingLotsofGPs;
begin
if FindNormalRandoms then
begin
Logout;
TerminateScript;
end
else
IncesRight;
Wait(3000 + Random(50));
InceLeft;
Wait(3000 + Random(50));
Giving;
Wait(45000 + Random(50));
Glory;
end;
procedure FreDTM;
begin
FreeDTM(InfernAsh);
FreeDTM(Bones);
FreeDTM(Herb);
FreeDTM(TeleTab);
FreeDTM(Door);
FreeDTM(GAltar);
FreeDTM(MountGlory);
FreeDTM(IncenseLeft);
FreeDTM(IncenseLeftBack);
FreeDTM(IncenseRight);
end;
begin
MouseSpeed := RandomRange(14, 16);
smart_server := 16;
smart_members := false;
smart_signed := true;
smart_superDetail := false;
SetupSRL;
SetDTM;
DeclarePlayers;
LoginPlayer;
ClickNorth(SRL_ANGLE_HIGH);
SetRun(True);
repeat
Wait(500 + Random(50));
WalkingtoBank;
Banking;
OpeningDoor;
WastingLotsofGPs;
until (not Loggedin);
FreDTM;
end.
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.