SRL Archive - RS3 Script Requests

Simple Firemaking Script


SOmesand

2014-09-24 14:17:36

I've been cutting wood a lot lately with the Coh3n's chop & bank script. I have around 30000 logs in the bank at the moment… I am thinking of making a script that will burn these logs, collect ashes, and bank them. I'm new to this, but I'm slowly learning from the tutorials and also looking at the woodcutting script and seeing how it works. If someone could make a really simple fire making script that would burn logs in front of the bank at dray nor village, I would really appreciate it.

Lipcot

2014-09-24 16:06:18

program FireMaker;

{$DEFINE SMART}
{$I SRL-6/SRL.simba}
{$I SPS/lib/SPS-RS3.Simba}

var
loadsdone: integer;

procedure declarePlayers();
begin
setLength(players, 1);
with players[0] do
begin
loginName := '';
password := '';
isActive := true;
isMember := false;
World := 100;
end
currentPlayer := 0;
end;

function FindFire(): boolean;
var
x, y, i, r: integer;
TPA: TPointArray;
ATPA: T2DPointArray;
begin

if findColorsSpiralTolerance(x, y, TPA, 3125185, mainScreen.getBounds(), 13, colorSetting(2, 0.19, 0.88)) then
begin
writeLn('We Found a Bonfire!');
result := true;
writeLn('We Found a Bonfire!');
end else
begin
result := false;
writeLn('We Didnt Find a Bonfire, Making One');
end;

end;

function notMoving(): boolean;
begin
result := not minimap.isPlayerMoving();
print('Function notMoving() result: ' + boolToStr(result));
end;

function AddingToBonfire(): boolean;
var
count1, count2, count3: integer;
begin

count1 := tabBackpack.count();
wait(randomRange(5500, 6000));
count2 := tabBackpack.count();
count3 := (count1 - count2);

if count3 >= 1 then
result := true;

if count3 <1 then
result := false;

print('Function AddingToBonfire() result: ' + booltostr(result));
end;

procedure LightFire();

var
mybox: tbox;
mybox2: tbox;

begin

myBox := intToBox(162, 187, 206, 224);
myBox2 := intToBox(265, 106, 300, 124);
repeat
begin
mouseBox(mybox2, MOUSE_LEFT);
if notmoving() then
begin
SendKeys('0', 50, 30);
wait(randomRange(3000, 4000));
mouseBox(mybox, MOUSE_LEFT);
tabBackpack.waitForShift(1000);
wait(randomRange(7000, 10000));
end;
end;

until findfire();
end;

procedure clickchest();
var
x, y, i: integer;
TPA: TPointArray;
ATPA: T2DPointArray;

begin
if not isLoggedIn() then
exit;
repeat
findColorsSpiralTolerance(x, y, TPA, 6587300, mainScreen.getBounds(), 3, colorSetting(2, 0.25, 0.84));

if (Length(TPA) < 1) then
exit;

ATPA := TPA.toATPA(30, 30);
ATPA.sortFromMidPoint(mainscreen.playerPoint);
smartImage.debugATPA(ATPA);

for i := 0 to high(ATPA) do
begin
mouse(middleTPA(ATPA[i]), MOUSE_MOVE);
if isMouseOverText(['hest'], 500) then
begin
fastClick(MOUSE_LEFT);
wait(randomrange(3000, 4000));
smartImage.clear();
break;
end;
end;
until bankscreen.isopen;
end;


procedure preset1();
begin

sleepAndMoveMouse(1000 + random(500));
bankScreen.clickButton(BANK_BUTTON_PRESET_1);
wait(randomrange(655, 1000));

end;

procedure antiban();
begin

case randomRange(1,102) of
1..30: begin
writeLn('Simulating Checking Social Networks');
mouseOffClient(OFF_CLIENT_RANDOM);
wait(randomRange(40000, 50000));
end;
31..41: begin
writeLn('Simulating Bored Human');
boredHuman();
wait(randomRange(5000, 10000));
end;
42..102: begin
writeLn('Simulating Small afk');
sleepAndMoveMouse(500 + random(1000));
wait(randomRange(8000, 12000));
pickUpMouse();
end;
end;
end;

procedure AddTobonfire();
var
mybox: tbox;
begin
myBox := intToBox(362, 187, 407, 224);

repeat

if not AddingToBonfire() then
begin
if tabBackpack.isEmpty then
begin
break;
exit;
end;
SendKeys('0', 50, 30);
wait(randomRange(1000, 2000));
if ToolScreen.isOpen then
begin
writeln('Toolscren is open!');
if ToolScreen.select('Add') then
writeln('We are adding to bonfire!');
// mouseBox(mybox, MOUSE_LEFT);
end;
if random(9) = 4 then
smallRandomMouse(80 + random(100));
if random(10) = 1 then
mouseOffClient(OFF_CLIENT_RANDOM);

wait(randomRange(9000, 15000));

if random(4) = 1 then
antiban();
end;

until AddingToBonfire();

end;



// main loop
begin
smartPlugins := ['d3d9.dll'];
clearDebug();
smartEnableDrawing := true;
smartShowConsole := false;
setupSRL();
declarePlayers();
disableSrlDebug := false;

repeat
if not isLoggedIn() then
begin
players[currentPlayer].login();
exitSquealOfFortune();
mainScreen.setAngle(MS_ANGLE_HIGH);
minimap.setAngle(MM_DIRECTION_NORTH);
end;

if tabBackpack.isEmpty then
begin
clickchest();
Preset1();
end;

addtobonfire();


until (false)
end.

This is for Shantay pass (on members world) so well.. check if you can use it for something, you will have to edit things though!

This one ive used it to get to a mere 50 FM on a few accs and worked fine.

SOmesand

2014-09-25 14:20:18

From: undorak7


This is for Shantay pass (on members world) so well.. check if you can use it for something, you will have to edit things though!

This one ive used it to get to a mere 50 FM on a few accs and worked fine.


Thanks. I'll definitely edit it and mess with it.

cbrems

2014-10-02 14:29:46

firemaking works well, thanks :)