SRL Archive - First Scripts

MapleCutter


MagicClty

2012-06-05 20:49:54

POWERMAPLECUTTER

First off this is my very first script. I hope this will begin a good career to script making! I plan to make this script flawless, or near to it, because I'm the type of person that does things "perfect". Also, because I'm a beginner at this, support is highly welcomed!
This is a plain reliable script.
Below in quotes is the script.

program MapleChopper;
{$DEFINE SMART}
{$i srl/srl.simba}

Procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;

Players[0].Name := '';
Players[0].Pass := '';
Players[0].Nick := '';
Players[0].Active:=True;
end;
procedure AntiBan;
begin
if(not(LoggedIn))then
Exit;
FindNormalRandoms;
case Random(8) of
0:
begin
HoverSkill('Woodcutting', false);
wait(2453+Random(432));
end;
1: PickUpMouse;
2:
begin
MakeCompass('N');
wait(100+random(133));
MakeCompass('S');
wait(50+random(133));
MakeCompass('N');
FindNormalRandoms;
end;
end;
end;
procedure ChopTree;
var x, y: integer;
begin
repeat
if FindObj(x, y, 'hop', 3683711, 20) then
begin
Mouse(x, y, 2, 2, false);
ChooseOption('hop');
end;
repeat
Wait(400+random(250));
AntiBan;
Until not IsUpText('aple') or (InvFull);
until(InvFull);
if (InvFull)then
end;

begin
SetUpSRL;
ActivateClient;
DeclarePlayers;
LoginPlayer;
SetupRandomTool(10000, 5, 'C:/Simba/randomSound.mp3');
ChopTree;
DropAllExcept([1]);
end.


I plan to get better at scripting, because personally, I have enjoyed creating my first one.

Turpinator

2012-06-05 21:16:28

DropItem(invslot);
DropAll;
DropAllExcept([ignoredslot1,3,etc]);

So in your case, assuming you have the axe equiped, just use DropAll.


and for pasting code, use
 tags so it will keep everything formatted properly.

MagicClty

2012-06-06 17:19:50

Thankyou for the help! That information really helps me out.:thumbsup:

Joe

2012-06-06 17:28:44

You can work on your standards - but thats just something I have to say as a member.
It looks good! With any luck, you'll be a member soon enough. Try out some advanced functions like TPAs. Good job though. Rep+ fo sho!

MagicClty

2012-06-06 19:49:18

Thanks alot for the support, I'll look into adding that for sure!

MagicClty

2012-06-10 22:54:42

Anyone have any reports, errors, or ideas to suggest?