Shuttleu
2008-05-10 07:30:02
<!– BEGIN TEMPLATE: formanswers –>
shuttleu - SRL Member Application Form
shuttleu
What is the meaning to life?
Where you Referred to SRL? If yes, by whom?
no
Programming Knowledge
HTML, PHP,
Other Communitys
none
How Long have You Played Runescape
2 years
Are you affilated in anyway with Jagex LTD?
No
—————————————————–
Please write down a paragraph about Yourself.
i have been learning how to script for about 6 months and i am into the advanced section.
i have made one script from scratch and i have fixed up and updated quite a few old scripts including scripts which have become outdated and the owners have been too busy to fix.
i have helped people in the SRL FAQ area i have also helped in the scripts request area as well.
i have been recommended to become a srl member by other SRL Members and SRL Juior Members.
——————————————————
Please Post a Sample of your Work. Only SCAR Scripts Accepted
——————————————————
<!– END TEMPLATE: formanswers –>
shuttleu - SRL Member Application Form
shuttleu
What is the meaning to life?
Where you Referred to SRL? If yes, by whom?
no
Programming Knowledge
HTML, PHP,
Other Communitys
none
How Long have You Played Runescape
2 years
Are you affilated in anyway with Jagex LTD?
No
—————————————————–
Please write down a paragraph about Yourself.
i have been learning how to script for about 6 months and i am into the advanced section.
i have made one script from scratch and i have fixed up and updated quite a few old scripts including scripts which have become outdated and the owners have been too busy to fix.
i have helped people in the SRL FAQ area i have also helped in the scripts request area as well.
i have been recommended to become a srl member by other SRL Members and SRL Juior Members.
——————————————————
Please Post a Sample of your Work. Only SCAR Scripts Accepted
{.Script Info:
# ScriptName = CMHT
# Author = shuttleu
# Description = Tans cow hides in al-kharid
# Version = v 2.6
# Date = 10/05/08
# Comments =
/Script Info}
program New;
{-------------------------------------------------------------------------------]
[ __ __ ___ _ _ ________ ]
[ | \ / |/ _ \| | | |___ ___| ]
[ | \/ | / \_| |__| | | | ]
[ | |\ /| | | _| __ | | | ]
[ | | \/ | | \_/ | | | | | | ]
[ |_| |_|\___/|_| |_| |_| ]
[ Master Crafter Hide Tanner V2. ]
[ by shuttleu ]
[ ]
[===============================================================================]
[ ]
[ NAME : MCHT (Master Crafter Hide tanner) ]
[ AUTHOR : shuttleu ]
[ CATEGORY : Crafting ]
[ DESCRIPTION : Tans hides in al-kharid. ]
[ MEMBERS ONLY : No ]
[ MULTIPLAYER : Yes ]
[ SCAR VERSION : 3.15 ]
[ SRL VERSION : 4 #rev 16 ]
[ RELEASE DATE : 10/05/2008 ]
[ ]
[===============================================================================]
[ ]
[ 01. Use the offcial runescape client (or SMART), with low detail and very ]
[ bright. Set your screen resolution to 32bit true colour. ]
[ 02. Setup lines 45 to 55 (or more thean 55 if you have more than one player. ]
[ 03. Put money in first bank slot and cowhide in anyother slot as long as it ]
[ is at the top 6 ]
[ 03. Position your runescape characters in the bank at al-kharid ]
[ 04. Drag the crosshair over the runescape client and press play. ]
[ 05. Enjoy the script and please post progress/feedback :D ]
[ ]
[-------------------------------------------------------------------------------}
{.include srl/srl/misc/smart.scar}
{.include SRL\SRL.scar}
var
x, y, randomtime, totalhides, running, randomtime1, break1, breakwait1: integer;
loads, HideDTM, SoftDTM, ShopDTM, HardDTM: integer;
const
maxloads = 100; // maximum amount of loads to do before the script finishes
break = 10;
breakwait = 5;
world = 6; // world number for smart to load
SRL_ID = 'ID';
SRL_PASS = 'Pass';
procedure DeclarePlayers;
begin
HowManyPlayers:= 1; // Set Number of Players here.
NumberOfPlayers(HowManyPlayers); // Sets the Players Array Length;
CurrentPlayer:= 0; // CurrentPlayer = Array Index
Players[0].Name:= 'username'; // Your username
Players[0].Pass:= 'pass'; // Your password
Players[0].Nick:= 'sern'; // Few letters From Your Name
Players[0].Pin:= '0000'; // Bank pin (if you have one, otherwise leave as 0000)
Players[0].integers[0]:= 100; // Amount of loads to do before the script changes player
Players[0].strings[0]:= 'soft'; // type of lether to make the hides into (soft or hard)
Players[0].Active:= True; // If You use This Player Set True
end;
{======================================================================================]
DO NOT EDIT ANYTHING BELOW THIS LINE UNLESS YOU HAVE PERMISSION FROM SHUTTLEU FIRST!!!
[======================================================================================}
{*******************************************************************************
procedure WhichDDTM(DDTM: string): Integer
By: shuttleu
Description: stores all the DTMs and declares one when needed
*******************************************************************************}
procedure WhichDDTM(DDTM: string);
begin
if not(LoggedIn) then Exit;
case DDTM of
'hide':
begin
HideDTM := DTMFromString('78DA65CEC10A404010C6F1590FE2E11C94521' +
'26FE3C089880BC9B622AD5AE5E09598BDC897FF656AFA358D081D' +
'A259D037D975E4F2B4DB9B13D60C68FAAA7C8D4D786C5634D761D' +
'0446C0C9A5D2934291B89A62D7234F1FF9F2ACBD0F8FF3BDB34A1' +
'09D86834A7D66812360B9AB1A9C13C2DD3228B');
end;
'soft':
begin
SoftDTM := DTMFromString('78DA633CC8C4C0B087910119F8B87332C8016' +
'990E87F2060DC0D54B309B71A10603C0E54B30D558DA32D07AA9A' +
'234035470998B313A8E620AA9A406F2E54353B806A761130E7105' +
'0CD6602EE3981E977372734357B816A8EE0770F00D03F17E6');
end;
'hard':
begin
HardDTM := DTMFromString('78DA639CCEC4C0B0979101199819C831C8016' +
'990E87F20609C0A54B311558DA1B60C5C0D0830F602D5EC435563' +
'6DA288AA661650CD51DC7681D52C00AAD94EC0AEB940350708983' +
'301D31C0CF74C02AA398CAAC6DE4219D3CD9BF1BB07005ED415C7' +
'');
end;
'shop':
begin
ShopDTM := DTMFromString('78DA631460606070666440067C7C3C0C72401' +
'A24FA1F0818BF33E25503026035120CF8D580EC22A48605C8D240' +
'55F37F863CAA9A8940421BB71A66109DC588570D0B100300CFFC0' +
'EED');
end;
end;
end;
{*******************************************************************************
procedure Coins;
By: shuttleu
Description: Withdraws the coins from the bank.
*******************************************************************************}
procedure Coins;
begin
if not(LoggedIn) then Exit;
case Players[currentplayer].strings[0] of
'soft':
begin
withdraw(1, 1, 27);
end;
'hard':
begin
withdraw(1, 1, 81);
end;
end;
end;
{*******************************************************************************
procedure Tanning;
By: shuttleu
Description: Tans the hides when inside the tanning screen.
*******************************************************************************}
procedure Tanning;
begin
if not(LoggedIn) then Exit;
case Players[currentplayer].strings[0] of
'soft':
begin
Mouse(59, 74, 60, 68, false);
Wait(1000 +random(500));
ChooseOption('All');
end;
'hard':
begin
Mouse(170, 80, 60, 68, false);
Wait(1000 +random(500));
ChooseOption('All');
end;
end;
end;
{*******************************************************************************
function AutoTannerSymb; Integer;
By: ACA V2 (Nielsie95 and Sumilion)
Description: Returns the color of the tanner symbol.
*******************************************************************************}
function AutoTannerSymb: Integer;
var
arP: TPointArray;
arC: TIntegerArray;
tmpCTS, i, arL: Integer;
R, G, B: Integer;
H, S, L: Extended;
X, Y, Z: Extended;
begin
if not(LoggedIn) then Exit;
tmpCTS := GetColorToleranceSpeed;
ColorToleranceSpeed(1);
if not (FindColorsTolerance(arP, 1256009, MMX1, MMY1, MMX2, MMY2, 33)) then
begin
Writeln('Failed to find the tanner color, no result.');
ColorToleranceSpeed(tmpCTS);
Exit;
end;
arC := GetColors(arP);
ClearSameIntegers(arC);
arL := High(arC);
for i := 0 to arL do
begin
if (rs_OnMinimap(arP[i].x, arP[i].y)) then
begin
ColorToRGB(arC[i], R, G, B);
if (R >= 51) and (R <= 95) and (G >= 23) and (G <= 60) and (B >= 1) and (B <= 36) then
begin
ColorToHSL(arC[i], H, S, L);
if (H >= 3.52) and (H <= 8.91) and (S >= 42.13) and (S <= 92.61) and (L >= 10.57) and (L <= 23.75) then
begin
ColorToXYZ(arC[i], X, Y, Z);
if (X >= 1.73) and (X <= 6.32) and (Y >= 1.37) and (Y <= 5.58) and (Z >= 0.21) and (Z <= 2.24) then
begin
Result := arC[i];
Writeln('TannerColor = ' + IntToStr(arC[i]));
Break;
end;
end;
end;
end;
end;
ColorToleranceSpeed(tmpCTS);
if (i = arL + 1) then
Writeln('AutoColor failed in finding the tanner color.');
end;
{*******************************************************************************
function AutoFurnaceSymb; Integer;
By: ACA V2 (Nielsie95 and Sumilion)
Description: Returns the color of the furnace symbol.
*******************************************************************************}
function AutoFurnaceSymb: Integer;
var
arP: TPointArray;
arC: TIntegerArray;
tmpCTS, i, arL: Integer;
R, G, B: Integer;
H, S, L: Extended;
X, Y, Z: Extended;
begin
if not(LoggedIn) then Exit;
tmpCTS := GetColorToleranceSpeed;
ColorToleranceSpeed(1);
if not (FindColorsTolerance(arP, 1072113, MMX1, MMY1, MMX2, MMY2, 28)) then
begin
Writeln('Failed to find the furnace color, no result.');
ColorToleranceSpeed(tmpCTS);
Exit;
end;
arC := GetColors(arP);
ClearSameIntegers(arC);
arL := High(arC);
for i := 0 to arL do
begin
if (rs_OnMinimap(arP[i].x, arP[i].y)) then
begin
ColorToRGB(arC[i], R, G, B);
if (R >= 226) and (R <= 256) and (G >= 72) and (G <= 109) and (B >= 0) and (B <= 32) then
begin
ColorToHSL(arC[i], H, S, L);
if (H >= 4.76) and (H <= 6.48) and (S >= 88.91) and (S <= 100.02) and (L >= 44.69) and (L <= 56.10) then
begin
ColorToXYZ(arC[i], X, Y, Z);
if (X >= 34.05) and (X <= 46.71) and (Y >= 21.08) and (Y <= 32.05) and (Z >= 2.29) and (Z <= 4.87) then
begin
Result := arC[i];
Writeln('FurnaceColor = ' + IntToStr(arC[i]));
Break;
end;
end;
end;
end;
end;
ColorToleranceSpeed(tmpCTS);
if (i = arL + 1) then
Writeln('AutoColor failed in finding the furnace color.');
end;
{*******************************************************************************
function AutoBankSymb; Integer;
By: ACA V2 (Nielsie95 and Sumilion)
Description: Returns the color of the bank symbol.
*******************************************************************************}
function AutoBankSymb: Integer;
var
arP: TPointArray;
arC: TIntegerArray;
tmpCTS, i, arL: Integer;
R, G, B: Integer;
H, S, L: Extended;
X, Y, Z: Extended;
begin
if not(LoggedIn) then Exit;
tmpCTS := GetColorToleranceSpeed;
ColorToleranceSpeed(1);
if not (FindColorsTolerance(arP, 1364967, MMX1, MMY1, MMX2, MMY2, 30)) then
begin
Writeln('Failed to find the bank color, no result.');
ColorToleranceSpeed(tmpCTS);
Exit;
end;
arC := GetColors(arP);
ClearSameIntegers(arC);
arL := High(arC);
for i := 0 to arL do
begin
if (rs_OnMinimap(arP[i].x, arP[i].y)) then
begin
ColorToRGB(arC[i], R, G, B);
if (R >= 214) and (R <= 248) and (G >= 194) and (G <= 228) and (B >= 0) and (B <= 40) then
begin
ColorToHSL(arC[i], H, S, L);
if (H >= 13.89) and (H <= 15.16) and (S >= 82.91) and (S <= 99.09) and (L >= 42.33) and (L <= 55.90) then
begin
ColorToXYZ(arC[i], X, Y, Z);
if (X >= 47.53) and (X <= 65.86) and (Y >= 53.46) and (Y <= 74.70) and (Z >= 7.83) and (Z <= 12.89) then
begin
Result := arC[i];
Writeln('Bank Color = ' + IntToStr(arC[i]));
Break;
end;
end;
end;
end;
end;
ColorToleranceSpeed(tmpCTS);
if (i = arL + 1) then
Writeln('AutoColor failed in finding the bank color.');
end;
{*******************************************************************************
function FindCactus(sx, sy, ex, ey : integer) : boolean
By: shuttleu
Description: Returns true if cactus is found within specified area.
*******************************************************************************}
function FindCactus(sx, sy, ex, ey : integer) : boolean;
var
cactus : integer;
begin
if not(LoggedIn) then Exit;
cactus := BitmapFromString(7, 8, 'beNpjYIADUy9pm2h' +
'ZIANI+piKYAoC2UAEYaMJQpTBEUQjsiADEsAUQbYIuyAAF28T3A==' +
'');
if FindDeformed(x, y, cactus, sx, sy, ex, ey) then
begin
FreeBitmap(cactus);
Writeln('Found cactus');
Result:= True;
end else
begin
FreeBitmap(cactus);
Writeln('Could not find cactus');
Result:= False
end;
end;
{*******************************************************************************
function FindObjCustom1(var cx, cy: Integer; Text: TStringArray; Color: TIntegerArray;
Tolerance: Integer): Boolean;
By: Stupid3ooo and Starblaster100
Description: Finds Object with custom amount of colors and custom amount of Uptext
Use: FindObjCustom(x, y, ['att', 'ack'], [123456, 345678], 5)
*******************************************************************************}
//Taken from SRL rev#14 because i dont like the way it works in rev#15
function FindObjCustom1(var cx, cy: Integer; Text: TStringArray; Color: TIntegerArray; Tolerance: Integer): Boolean;
var
a, b, c, i, x1, y1, x2, y2: Integer;
Start: Boolean;
begin
if not(LoggedIn) then Exit;
for b := 0 to (GetArrayLength(Color)-1) do
begin
if (FindColorSpiralTolerance(cx, cy, color[b], MSX1, MSY1, MSX2, MSY2, Tolerance)) then
begin
Start := True;
Break;
end;
end;
if(Start)then
begin
x1 := 245;
y1 := 165;
x2 := 277;
y2 := 185;
repeat
if not(LoggedIn)then break;
a := a + 1;
if (a = 1) then
c := c + 1
else if (a = 3) then
c := c + 1;
for i := 1 to c do
begin
if (a = 1) then
begin
x1 := x1 + 30;
x2 := x2 + 30;
end else
if (a = 2) then
begin
y1 := y1 - 20;
y2 := y2 - 20;
end else
if (a = 3) then
begin
x1 := x1 - 30;
x2 := x2 - 30;
end else
if (a = 4) then
begin
y1 := y1 + 20;
y2 := y2 + 20;
end;
if (x1 = 485) and (x2 = 517) then
x2 := x2 - 2;
if (y1 = 325) and (y2 = 345) then
y2 := y2 - 7;
if (x2 > 515) then
Break;
for b := 0 to (GetArrayLength(Color)-1) do
begin
if (FindColorTolerance(cx, cy, Color[b], x1, y1, x2, y2, tolerance)) then
begin
MMouse(cx, cy, 0, 0)
if (IsUpTextMultiCustom(Text)) then
begin
Result := True;
Exit;
end;
end;
end;
end;
if (a = 4) then
a := 0;
until (x2 > 515) or (Result = True);
end;
end;
{*******************************************************************************
function ShopScreen
By: shuttleu
Description: returns true if the shop screen is open.
*******************************************************************************}
function ShopScren : Boolean;
begin
if not(LoggedIn) then Exit;
whichDDTM('shop')
if findDTM(ShopDTM, x, y, MSX1, MSY1, MSX2, MSY2) then
begin
FreeDTM(ShopDTM);
Writeln('Found shop screen');
Result := True;
end else
begin
FreeDTM(ShopDTM);
Result := False;
end;
end;
{*******************************************************************************
procedure Error(where: string)
By: shuttleu
Description: Gives a little error message.
*******************************************************************************}
procedure Error(where: string; reason: string);
begin
Writeln('Failed while '+where+'. Reason : '+reason);
end;
{*******************************************************************************
procedure Banking
By: shuttleu
Description: Opens the al-kharid bank and deposits everything and withdraws
cowhides and money.
*******************************************************************************}
procedure Banking;
var
withdrawhides : integer;
begin
if not(LoggedIn) then Exit;
FFlag(0);
OpenBankQuiet('akb');
if Pinscreen then Inpin(players[currentplayer].pin);
FixBank;
DepositAll;
Coins;
WhichDDTM('hide')
if not(FindDTM(HideDTM, x, y, MSX1, MSY1, MSX2, MSY2)) then
begin
FreeDTM(HideDTM);
CloseBank;
Error('withdrawing cowhides', 'No cowhides left in the bank');
Logout;
NextPlayer(false);
Exit;
end else
begin
MarkTime(withdrawhides);
repeat
MMouse(x, y, 5, 5);
Wait(500 +random(500));
Getmousepos(x, y);
Mouse(x, y, 0, 0, false);
Wait(500 +random(500));
ChooseOption('Withdraw All');
Wait(1000 +random(1000));
until FindDTM(HideDTM, x, y, MIX1, MIY1, MIX2, MIY2) or (TimeFromMark(withdrawhides) >= 30000)
FreeDTM(HideDTM);
if TimeFromMark(withdrawhides) >= 30000 then
begin
CloseBank;
Error('withdrawing cowhides', 'No cowhides left in the bank');
Logout;
NextPlayer(false);
Exit;
end else
end;
CloseBank;
FindNormalRandoms;
end;
function CactusCol: Integer;
var
arP: TPointArray;
arC: TIntegerArray;
tmpCTS, i, arL: Integer;
R, G, B: Integer;
H, S, L: Extended;
X, Y, Z: Extended;
begin
if not(LoggedIn) then Exit;
tmpCTS := GetColorToleranceSpeed;
ColorToleranceSpeed(1);
if not (FindColorsTolerance(arP, 3304777, MMX1, MMY1, MMX2, MMY2, 33)) then
begin
Writeln('Failed to find the cactus color, no result.');
ColorToleranceSpeed(tmpCTS);
Exit;
end;
arC := GetColors(arP);
ClearSameIntegers(arC);
arL := High(arC);
for i := 0 to arL do
begin
if (rs_OnMinimap(arP[i].x, arP[i].y)) then
begin
ColorToRGB(arC[i], R, G, B);
if (R >= 58) and (R <= 88) and (G >= 85) and (G <= 133) and (B >= 30) and (B <= 69) then
begin
ColorToHSL(arC[i], H, S, L);
if (H >= 23.98) and (H <= 28.91) and (S >= 31.98) and (S <= 50.02) and (L >= 23.90) and (L <= 39.24) then
begin
ColorToXYZ(arC[i], X, Y, Z);
if (X >= 5.74) and (X <= 13.24) and (Y >= 7.85) and (Y <= 18.97) and (Z >= 2.67) and (Z <= 8.45) then
begin
Result := arC[i];
Writeln('Cactus Color = ' + IntToStr(arC[i]));
Break;
end;
end;
end;
end;
end;
ColorToleranceSpeed(tmpCTS);
if (i = arL + 1) then
Writeln('AutoColor failed in finding the cactus color.');
end;
{*******************************************************************************
procedure WalkToTanner
By: shuttleu
Description: Walks from the bank in al-kharid to the tan shop in al-kharid
using symbols and then color.
*******************************************************************************}
procedure WalkToTanner;
var
tpa: TPointArray;
i: Integer;
begin
if not(LoggedIn) then Exit;
FindNormalRandoms;
begin
if FindCactus(628, 2, 712, 100) then
begin
MMouse(x, y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find cactus by bitmap, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, cactuscol, 30, 20, 90, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to tanner', 'could not find cactus by bitmap or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
if FindSymbol(x, y, 'furnace') then
begin
MMouse(x, y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find furnace by symbol, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, AutoFurnaceSymb, 30, 320, 370, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to tanner', 'could not find furnace by symbol or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
if FindSymbol(x, y, 'tanner') then
begin
MMouse(x, y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find tanner by symbol, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, AutoTannerSymb, 30, 290, 380, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to tanner', 'could not find tanner by symbol or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
end;
end;
{*******************************************************************************
procedure WalkToBank
By: shuttleu
Description: Walks from the tan shop in al-kharid to the bank in al-kharid
using the DTMs.
*******************************************************************************}
procedure WalkToBank;
var
tpa: TPointArray;
i: Integer;
begin
if not(LoggedIn) then Exit;
FindNormalRandoms;
begin
if findsymbol(x, y, 'furnace') then
begin
MMouse(x, y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 01, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find furnace by symbol, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, AutoFurnaceSymb, 30, 230, 120, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to bank', 'could not find furnace by symbol or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
if FindCactus(553, 102, MMX2, MMY2) then
begin
MMouse(x, y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find cactus by bitmap, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, cactuscol, 30, 120, 210, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to bank', 'could not find cactus by bitmap or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
if FindSymbol(x, y, 'bank') then
begin
MMouse(x, y, 1, 1);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Writeln('Unable to find bank by symbol, now trying color');
if RadialWalkEx(tpa, MMCX, MMCY, AutoBankSymb, 30, 280, 190, 70) then
begin
MMouse(tpa[i].x, tpa[i].y, 5, 5);
Wait(500 +random(500));
GetMousePos(X, Y);
Mouse(x, y, 0, 0, true);
Wait(3000);
FindNormalRandoms;
FFlag(0);
end else
begin
Error('walking to bank', 'could not find bank by symbol or color');
Logout;
NextPlayer(False);
Exit;
end;
end;
end;
end;
{*******************************************************************************
procedure TanHides
By: shuttleu
Description: Tans the cow hides into hard or soft leather.
*******************************************************************************}
procedure TanHides;
var
shop : integer;
begin
if not(LoggedIn) then Exit;
repeat
Marktime(shop);
if FindObjCustom1(x, y, ['alk', 'llis'], [4944848, 4680900], 30) then
FindNormalRandoms;
Mouse(x, y, 2, 2, False);
ChooseOption('rade');
Wait(1000 +random(1000));
until Shopscren or (TimeFromMark(shop) >= 30000 )
if TimeFromMark(shop) >= 30000 then
begin
Error('withdrawing cowhides', 'No cowhides left in the bank');
Logout;
NextPlayer(false);
Exit;
end;
Tanning;
repeat
Wait(500)
until not ShopScreen;
end;
procedure ReportVariables;
begin
if not(LoggedIn) then Exit;
case Players[currentplayer].strings[0] of
'soft':
begin
WhichDDTM('soft');
ReportVars[1] := ReportVars[1] + CountItemsDtm('inv', SoftDTM);
totalhides := totalhides + CountItemsDtm('inv', SoftDTM);
FreeDTM(SoftDTM);
end;
'hard':
begin
WhichDDTM('hard');
ReportVars[2] := ReportVars[2] + CountItemsDtm('inv', HardDTM);
totalhides := totalhides + CountItemsDtm('inv', HardDTM);
FreeDTM(HardDTM);
end;
end;
end;
procedure proggy;
begin
Writeln('[----------------------------------------------------------------]');
Writeln('[ __ __ ___ _ _ ________ ]');
Writeln('[ | \ / |/ _ \| | | |___ ___| ]');
Writeln('[ | \/ | / \_| |__| | | | ]');
Writeln('[ | |\ /| | | _| __ | | | ]');
Writeln('[ | | \/ | | \_/ | | | | | | ]');
Writeln('[ |_| |_|\___/|_| |_| |_| ]');
Writeln('[ ]');
Writeln('[================================================================]');
Writeln('[ ]');
Writeln('[ Worked for '+timerunning+' ]');
Writeln('[ Made '+inttostr(totalhides)+' hides ]');
Writeln('[ Banked '+inttostr(loads)+' times ]');
Writeln('[ ]');
Writeln('[ Thank you for using MCHT ]');
Writeln('[ ]');
Writeln('[----------------------------------------------------------------]');
end;
{*******************************************************************************
main loop
By: shuttleu
Description: Where the script all comes together.
*******************************************************************************}
begin
SmartSetupEx(world, False, True);
While Not (SmartReady) Do
Wait(100);
SetTargetDC(SmartGetDC);
If Not (LoggedIn) Then
While Not (SmartGetColor(386, 249) = 65535) Do
Wait(100);
ActivateClient;
SetupSrl;
ScriptId := '781';
SRLID := SRL_ID;
SRLPassword := SRL_PASS;
DeclarePlayers;
loads:= 0;
break1:= (break * 60000) * 60000
breakwait1:= (break1 * 60000) * 60000
MarkTime(running);
if not Loggedin then LoginPlayer;
repeat
SetAngle(True);
MakeCompass('n');
if TimeFromMark(running) > break1 then
MarkTime(running);
Banking;
if loggedin then
ReportVars[0] := ReportVars[0] + 1;
WalkToTanner;
TanHides;
WalkToBank;
Proggy;
if TimeFromMark(running) > break1 then
begin
randomtime:= random(300000);
randomtime1:= randomtime / 60000;
logout;
Writeln('Taking a break for '+inttostr(breakwait)+' minuites and a random '+inttostr(randomtime1)+' minuites');
LoginPlayer;
end;
ReportVariables;
loads:= loads + 1;
SrlRandomsReport;
if loads= Players[currentplayer].integers[0] then
begin
Logout;
NextPlayer(True);
loads:= 0;
end;
until loads= maxloads
Logout;
end.
——————————————————
<!– END TEMPLATE: formanswers –>