From: Smarter Child
I suggest making a real first script.
Chill out man, my first script didn't accomplish jack.
Karlkarlngng :
You had a good idea for a first script :) The execution is pretty fine, but
going through a number of commands without wait time will get you banned.
That's the first thing you should learn. The second one is that you should always head your scripts with {.include SRL/SRL.scar} and put SetupSRL; just after your main
begin.
Let me introduce you to a few functions that help your script go easier…
for..to..do : the first value is a starting variable, the second where it will stop. Basically, as long as the first variable isn't equal to the second value, it will run and run.
if..then : if test returns true, it will do what is after then.
ExistsItem : if item exists in specified slot, it will return true.
MouseItem : clicks item in item spot () :) (False) goes for a right click.
ChooseOption : Chooses option. When you right click, a box appears; it will search the box for the option you specify.
Inc() : raises the value of the variable in (..) by one. Here it's used to count the number of times you've dropped stuff !
Wait(RandomRange(500, 1000)); will wait between 500 and 1000 milliseconds.
Overall I see a great first try, especially by your own. If you have any questions there are a number of scripters out there that you can add on MSN and talk to for help, including me.
If you're the kind who likes to dig, you can use SCAR to open any file located in the SCAR/Includes/SRL/SRL/Core folder and browse through it. ChooseOption was in Text.scar since it searches for text, MouseItem and ExistsItem were in Inventory.scar, et cetera.
There are a number of interesting tutorials out there. :)
Here is something that would work. Notice the use of all the functions I mentioned earlier. Kudos to you if you can understand it ! If not, you can PM me for help :)
procedure DropItAll;
var i : Integer;
begin
for i:= 1 to 28 do
begin
if ExistsItem(i) then
begin
MouseItem(i, False);
Wait(RandomRange(200,400));
ChooseOption('Drop');
Wait(RandomRange(200, 500));
end;
end;
end;