SCAR Code:
// setup lines 11-13 and 22- 24
// replywhatsup and replyhi creds go to dudesareus
program Miner;
{.include SRL/SRL.scar}
const
RockColour = 2240332; //iron
runawaydirection1 = 'N';// N, E, S, W
TimeToMine=1; //How long it takes you to mine a pack in minutes
Procedure DeclarePlayers;
begin
HowManyPlayers:=1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name :='login_name';
Players[0].Pass :='login_pass';
Players[0].Nick :='4_letters_of_login_name';
Players[0].Active :=True;
end;
var
IronOreDTM, x, y: integer; //added x and y
DropIronOreDTM, S : Integer;
TooFullDTM : integer;
{------------------------------}
procedure MineIt; //changed
Var
MineStop: Integer;
begin
MarkTime(MineStop)
S:=S*1000
repeat
if (FindColorTolerance(x,y,RockColour, MSX1, MSY1, MSX2, MSY2, 5)) then //changed
Mouse(x, y, 2, 2,true);
FTWait(1000+random(1000));
until(InvFull) Or (TimeFromMark(MineStop) >= S)
end;
{------------------------------}
Procedure LoadDTMs;
begin
IronOreDTM := DTMFromString('78DA630C64606070614001CE1A32609A11CA6' +
'70C0012410C688011558D13482301351E40C28E801A905D9604D4' +
'4410A1261E48D81250130D247CF0AB01007110053E');
DropIronOreDTM := DTMFromString('78DA63CC6760608865C00A1861B43D906822A' +
'0269E08351544A8E92142CD1C22D46C00128D44A82920424D0211' +
'6A028850634940CD4220614A404D36903021A0C69B08357640C28' +
'D083589F8D50000D6D20E16');
TooFullDTM := DTMFromString('78DA637CC5C0C010C4800236CD2C05D38C503' +
'EA31D90B060C00AE06A4066381050930B24AC09A8E90212B604D4' +
'AC2542CD4622D49C0512F604D45C07125604D4BC20C2AEDF40C28' +
'E801A6146C26AAC180987732211E69413A1A6990835ED84D50000' +
'E0710F94');
end;
{------------------------------}
procedure DropIron;
begin
if (InvFull) then
if (findDTM(TooFullDTM, x, y, 555, 200, 705, 700))then
Repeat
if (findDTM(IronOreDTM, x, y, 555, 200, 705, 700))then
Mouse(x, y, 2, 2, false);
if (findDTM(DropIronOreDTM, x, y, 555, 200, 705, 700))then
Mouse(x, y, 2, 2, true);
Until(Not(findDTM(IronOreDTM, x, y, 555, 200, 705, 700)))
end;
{------------------------------}
procedure replywhatsup;
begin
if(FindChatText('whats up'))or
(FindChatText('whats new'))or
(FindChatText('whats hap'))then
typesend('not much, just mining!');
end;
{------------------------------}
procedure replyhi;
begin
if(FindChatText('hello'))or
(FindChatText('hi'))or
(FindChatText('hey'))or
(FindChatText('yo'))then
typesend('yo');
end;
{------------------------------}
procedure replymininglvls;
begin
if(FindChatText('min lvls'))or
(FindChatText('mine lvls'))or
(FindChatText('minin lvls'))or
(FindChatText('mining lvls'))then
typesend('not saying :D');
end;
{------------------------------}
procedure AntiRandoms;
begin
FindTalk;
FindNormalRandoms;
if (FindFight = true) then
begin
RunTo(runawaydirection1, True); //changed
Wait(10000 + random(2000));
RunBack;
end;
end;
{------------------------------}
Begin
SetupSRL;
DeclarePlayers;
repeat
S := TimeToMine;
MineIt; //changed
DropIron;
AntiRandoms;
replywhatsup;
replyhi;
replymininglvls;
until(false)
end.