SRL Archive - OSR Help

Experienced Programmer just looking for quick pointer


Xenobitz

2014-03-25 22:25:29

—

Frement

2014-03-25 22:50:31

Is this for RS3 or OSR?

Xenobitz

2014-03-26 00:04:12

—

Frement

2014-03-26 00:08:29

program new;
//{$DEFINE SMART8} //If you want to use SMART
{$I SRL-OSR/SRL.Simba}
//{$I SRL-OSR/SRL/Reflection/Reflection.simba} //If you want to use reflection

procedure DeclarePlayers;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name := '';
Players[0].Pass := '';
Players[0].Active := True;
end;

begin
DeclarePlayers; //Must be called before SetupSRL
SetupSRL;
//SetupReflection; //if you want to use reflection

if (not LoggedIn) then
LogInPlayer;

Sleep(10000); //Sleep 10 seconds

LogOut;
end.

EDIT: And a more suitable forum for future threads you may create regarding similar topics would be: http://villavu.com/forum/forumdisplay.php?f=491

Sk1nyNerd

2014-03-26 00:37:13

From: Xenobitz
This is for OSRS.

I've got my script working.

Here's my code for my theiving script to open a chest:

procedure Steal;
var x : Integer;
y : Integer;
Tries : Integer;
begin
if not LoggedIn then
Exit;
if (not (FindObjCustom(x, y, ['pen', 'est'], [5723998], 35))) then
begin
Wait(8500+Random(800));
end else
if FindObjCustom(x, y, ['pen', 'est'], [5723998], 35) then
begin Mouse(x, y, 4, 4, False);
ChooseOption('earch')
end;
end;

It's rather difficult to identify the chest I want using colors I've noticed. I will always log in standing in front of the chest I want, so maybe I can use that to my advantage.

Can you point me in the right direction for how to loop this code so that it continues looking for a right-click menu containing "Search Chest" even if it doesn't find it on the first try?


wow, impressive for being here for less than a day! :D

you can try using the Auto Coloring Aid (ACA) found in C:>Simba>Includes>SRL-OSR>Tools to pick better colors and thus enhancing ur finding. ACA is mostly used for picking colors, hues, and sats which are commonly used to create TPA and ATPAs of all the colors and sorting them to create the best object finding method. it is rather difficult and first but there should be some guides lurking around. ill post if i find any.

variables of the same type can be declared horizontally. x, y: integer;

one loop method is a repeat until();. it will repeat a sequence of commands until(this condition is met); if you take a look at my Willow Draynor Banker you will find a few usefull things for scripting. Looking and using other peoples code would a fast way to learn here. pnce u think u got the commands down try editing some of the code to make it do what u want

Gu3st...

2014-03-26 11:51:30

Welcome to the forums, Xenobitz! :)
I moved your thread to the correct sub-forum for you (thanks, Frement)

Xenobitz

2014-03-26 13:07:06

—

Frement

2014-03-26 13:11:31

From: Xenobitz
Much appreciated. I managed to get my script fully functional last night, so far it's thieved almost 4k nature runes without dying or having an error.

One question though, my script world hops every 30 seconds or so and it's taking a TON of "screenshots of IP log". I have the knowledge to open up the library and comment out a function, but I don't want to break anything. Where can I change the settings to not take screenshots?


After SetupSRL add:
SRL_DisableIPLog := True;

EDIT: Out of curiosity, where do you steal the natures at? And whats the level requirement?

Ian

2014-03-26 16:50:51

From: Frement
After SetupSRL add:
SRL_DisableIPLog := True;

EDIT: Out of curiosity, where do you steal the natures at? And whats the level requirement?


Ardougne or Rellekka, lv 28 required.

source: http://runescape.wikia.com/wiki/Thieving_Activities#Thievable_chests