SRL Archive - RS3 Outdated / Broken Scripts

i got like 100 scar scripts


mika

2011-02-03 22:04:32

I have a bunch of scar scripts and auto/macro programs from like 2006.
(simba didn't exists at that time) My question is can i share them here or do i need permission because i do not have permission from the authors of those scrips. I just happen to find a giant pack of them, so can i share them here?
I image they have a wealth of information in them.

3Garrett3

2011-02-03 22:09:34

You shouldn't bundle them, there's always a chance for malicious things to be hidden in a bundle.

mika

2011-02-03 22:11:43

i understand that but im pretty sure its virus free i can scan them if nessasary, but i would like to know if i can post them here or not?

3Garrett3

2011-02-03 22:14:16

There's been a few decisions made around it lately, specifically around CStrike's Guild Miner. The Staff decided that nobody could take over the project because it was CStrike's property and he had not given permission before he left.

I would say that you could share, simply because they wont compile anymore if they are for SCAR and from around 2006.

E: But I'm not staff so don't take my word.

mika

2011-02-03 22:43:54

here is the scrips pack i did not write any of them old but maybe useful[ATTACH]10555[/ATTACH]

XRaye

2011-02-03 23:00:53

Wow thanks a ton for posting that, it's awesome going back and noticing all the similarities and differences to today's coding :)

P3rs0nal1ty

2011-02-03 23:01:43

From: mika
here is the scrips pack i did not write any of them old but maybe useful[ATTACH]10555[/ATTACH]


>_> i dont know if u should have released that… no admins/mods/devs gave permission..?

Boreas

2011-02-04 00:23:11

All I can say is; please please please, do not show those to people that are learning the basics of scripting.

P3rs0nal1ty

2011-02-04 00:34:47

From: Boreas
All I can say is; please please please, do not show those to people that are learning the basics of scripting.


LOL yes that would be bad. considering the amazing amount of outdated coding
if someone learned off those…. :duh:

Wanted

2011-02-04 00:45:32

http://web.archive.org/web/20080614224547/www.scar-scripts.com/archive

FuruChan

2011-02-04 00:53:36

Then again, a lot of those scripts could be remade using modern scripting and there could be a whole library of old [updated] scripts. I mean I am sure a lot of them do the same thing as a lot of scripts out now, but there are some pretty unique things I remember from when I was using SRL a lot like Home's Flax Picker. Idk if that is in the bundle I haven't downloaded it, but it's an example :)

Wizzup?

2011-02-04 04:26:17

From: 3Garrett3
There's been a few decisions made around it lately, specifically around CStrike's Guild Miner. The Staff decided that nobody could take over the project because it was CStrike's property and he had not given permission before he left.

I would say that you could share, simply because they wont compile anymore if they are for SCAR and from around 2006.


I would like to see where this was decided, as no license was bundled with CStrike's code.

I don't see how it could hurt to release those scripts, I'd be interested although we have probably been most of them. :)

moparisthebest

2011-02-04 05:09:46

Hehe, thanks for posting this, I got a good laugh:

[        Moparisthebest's Ironminerbanker v2.1     ]

Although I don't see one of the required includes 'moparsroadrunner.txt', I remember working long hours on that, I wonder if I still have it someplace…

Anyway, great for a trip down memory lane. :)

edit: found it, I remember now, it followed roads in a certain direction until it found a certain color. It was very handy for walking and didn't rely on set coordinates. Is there anything comparable to it that exists and works today? It worked great back then, because all the roads were the same color, but I guess they aren't any more are they?

////////////////////////////////////////////////////////////////////////////////
// Mopar's RoadRunner (pun intended :P) v1.1 //
////////////////////////////////////////////////////////////////////////////////
// SET UP //
////////////////////////////////////////////////////////////////////////////////
// to use the road following procedures, set moparsroadcolor in your script //
// the coords of colors found are saved in variables colorx and colory //
////////////////////////////////////////////////////////////////////////////////
// Versions //
////////////////////////////////////////////////////////////////////////////////
// Version 0.7, All colorfinding procedures done, beta fally walking //
// Version 1.0, All walking procedures, fally and varrock bank-mine walking //
// Version 1.1, Ardougne bank-mine walking done //
////////////////////////////////////////////////////////////////////////////////
// Bugs/help etc. //
////////////////////////////////////////////////////////////////////////////////
// post them in the thread on kaitnieks.com, or msg me on msn messenger at //
// [email]moparisthebest@hotmail.com[/email] //
////////////////////////////////////////////////////////////////////////////////
const
randomclick=5; // how random the mouseclick is
maxpoints=10; // (default 10)maximum number of coords your going to send in your array
var colorx,colory,moparsroadcolor:integer;
coords:Array[1..12] of integer;

Function chkroadcolor:boolean;
begin
if(moparsroadcolor=0)then
writeln('you need to set moparsroadcolor before calling this function');
result:=(moparsroadcolor=0);
end;

Procedure roadrunnerFlag; // taken from ssi2
var flagimage,timeout,x,y:integer;
begin

flagimage := BitmapFromString(2, 2,'FF00005D3311C656045D3311');
timeout:=0
repeat
timeout:=timeout+1;
wait(250);
until(not findbitmapin( flagimage, x, y, 570, 5, 725, 162)) or (timeout > 120);
freebitmap(flagimage);
end;

Procedure roadrunnerantiFlag; // waits till flag does exist
var flagimage,timeout,x,y:integer;
begin

flagimage := BitmapFromString(2, 2,'FF00005D3311C656045D3311');
timeout:=0
if(not findbitmapin( flagimage, x, y, 570, 5, 725, 162))then
begin
repeat
timeout:=timeout+1;
wait(250);
until(not findbitmapin( flagimage, x, y, 570, 5, 725, 162)) or (timeout > 120);
end;
freebitmap(flagimage);
end;

Procedure roadrunnerMouse(mousex,mousey:integer); //modified from ssi2
var a,b,c,randx,randy:integer;
begin
case (random(4)+1) of
1:begin randx:=mousex+random(randomclick);randy:=mousey+random(randomclick);end;
2:begin randx:=mousex-random(randomclick);randy:=mousey-random(randomclick);end;
3:begin randx:=mousex+random(randomclick);randy:=mousey-random(randomclick);end;
4:begin randx:=mousex-random(randomclick);randy:=mousey+random(randomclick);end;
end;
MoveMouseSmoothEx(randx+1,randy, 2, 4, 30, 20, 10)
sleep(50+random(50));
GetMousePos(b,c);
HoldMouse(b+1,c,true);
repeat
wait(10+random(40));
a:=a+1;
until(a>4);
GetMousePos(b,c);
ReleaseMouse(b,c,true);
wait(500+random(100));
roadrunnerantiFlag;
wait(1000+random(100));
roadrunnerFlag;
end;

function roadrunnerfindcolor(color:integer):boolean;
begin
result:=(findcolorspiral(colorx,colory,color,565,5,725,160));
end;

/////////////////////////////////////////////////////
//finds color along the ycoord, from startx to endx//
/////////////////////////////////////////////////////
Function findhorizcolor(color,ycoord,startx,endx:integer):boolean;
var
found:boolean;
begin
colorx:=startx;
colory:=ycoord;
found:=false;
repeat
found:=(getcolor(colorx,ycoord)=color);
if((not(found))and(startx>endx))then
colorx:=colorx-1;
if((not(found))and(not(startx>endx)))then
colorx:=colorx+1;
until((found)or((colorx<endx)and(startx>endx))or((colorx>endx)and(not(startx>endx))))
result:=found;
end;

/////////////////////////////////////////////////////
//finds color along the xcoord, from starty to endy//
/////////////////////////////////////////////////////
Function findvertcolor(color,xcoord,starty,endy:integer):boolean;
var
found:boolean;
begin
colorx:=xcoord;
colory:=starty;
found:=false;
repeat
found:=(getcolor(xcoord,colory)=color);
if((not(found))and(starty>endy))then
colory:=colory-1;
if((not(found))and(not(starty>endy)))then
colory:=colory+1;
until((found)or((colory<endy)and(starty>endy))or((colory>endy)and(not(starty>endy))))
result:=found;
end;

///////////////////////////////////////////////////////
//finds color along the straight line drawn from //
// the startcoords to the endcoords //
///////////////////////////////////////////////////////
Function findlinecolor(color,startx,starty,endx,endy:integer):boolean;
var
found,posx,posy:boolean;
slopex,slopey:Extended;
begin
if(startx=endx)and(starty=endy)then
begin
result:=false;
exit;
end;
if(startx=endx)then
result:=findvertcolor(color,startx,starty,endy);
if(starty=endy)then
result:=findhorizcolor(color,starty,startx,endx);
if((not(starty=endy))and(not(startx=endx)))then
begin
slopex:=startx-endx;
posx:=(slopex>=0);
slopey:=starty-endy;
posy:=(slopey>=0);
if(slopex>slopey)then
begin
slopey:=abs(slopey/slopex);
slopex:=1;
end;
if(slopey>slopex)then
begin
slopex:=abs(slopex/slopey);
slopey:=1;
end;
colorx:=startx;
colory:=starty;
found:=false;
repeat
found:=(getcolor(colorx,colory)=color);
if(not(found))then
begin
if(posx)then
colorx:=round(colorx-slopex);
if(posy)then
colory:=round(colory-slopey);
if(not(posx))then
colorx:=round(colorx+slopex);
if(not(posy))then
colory:=round(colory+slopey);
end;
//movemousesmooth(colorx,colory);
//wait(10);
until(found)or(colorx=endx)or(colory=endy)
result:=found;
end;
end;

///////////////////////////////////////////////////////////////////////////////
//finds color along the multiple connected lines drawn from the coords array,//
//loaded with the x's in the odd numbers and the y's in the even numbers //
///////////////////////////////////////////////////////////////////////////////
Function findcurvedlinecolor(color:integer):boolean;
var c:integer;
found:boolean;
begin
c:=1;
repeat
found:=findlinecolor(color,coords[(c)],coords[(c+1)],coords[(c+2)],coords[(c+3)]);
c:=c+2;
until(found)or(12<(c+2))
result:=found;
end;

/////////////////////////////////////////////////////////////
//finds a road in the given direction, from the given side,//
/////////////////////////////////////////////////////////////
Function findroad(direction,fromside:string):boolean;
var toporleft:boolean;
begin
case fromside of
'T','t','TOP' : toporleft:=true;
'B','b','BOTTOM' : toporleft:=false;
'R','r','RIGHT' : toporleft:=false;
'L','l','LEFT' : toporleft:=true;
end;
case direction of
'N','n','NORTH': begin
if(toporleft)then
result:=(findhorizcolor(moparsroadcolor,30,595,700));
if(not(toporleft))then
result:=(findhorizcolor(moparsroadcolor,30,700,595));
end;
'E','e','EAST' : begin
if(toporleft)then
result:=(findvertcolor(moparsroadcolor,696,25,125));
if(not(toporleft))then
result:=(findvertcolor(moparsroadcolor,696,125,25));
end;
'S','s','SOUTH': begin
if(toporleft)then
result:=(findhorizcolor(moparsroadcolor,125,595,700));
if(not(toporleft))then
result:=(findhorizcolor(moparsroadcolor,125,700,595));
end;
'W','w','WEST' : begin
if(toporleft)then
result:=(findvertcolor(moparsroadcolor,600,25,125));
if(not(toporleft))then
result:=(findvertcolor(moparsroadcolor,600,125,25));
end;
'NW','nw','NORTHWEST': begin
if(toporleft)then
result:=(findlinecolor(moparsroadcolor,648,8,574,79));
if(not(toporleft))then
result:=(findlinecolor(moparsroadcolor,574,79,648,8));
end;
'NE','ne','NORTHEAST' : begin
if(toporleft)then
result:=(findlinecolor(moparsroadcolor,648,8,720,79));
if(not(toporleft))then
result:=(findlinecolor(moparsroadcolor,720,79,648,8));
end;
'SW','sw','SOUTHWEST': begin
if(toporleft)then
result:=(findlinecolor(moparsroadcolor,574,79,647,141));
if(not(toporleft))then
result:=(findlinecolor(moparsroadcolor,647,141,574,79));
end;
'SE','se','SOUTHWEST' : begin
if(toporleft)then
result:=(findlinecolor(moparsroadcolor,720,79,647,141));
if(not(toporleft))then
result:=(findlinecolor(moparsroadcolor,647,141,720,79));
end;
end;
end;

///////////////////////////////////////////////////////////////////////////////
//walks in a direction, along the specified side of road, for specified steps//
///////////////////////////////////////////////////////////////////////////////
procedure walkalongsteps(direction,fromside:string;steps:integer);
var i:integer;
begin
if(chkroadcolor)then Exit;
repeat
i:=i+1;
if(not(steps=1))then
status('Walking '+direction+' '+inttostr(i)+'/'+inttostr(steps));
if(findroad(direction,fromside))then
roadrunnerMouse(colorx,colory);
until(i=steps)
status('');
end;

/////////////////////////////////////////////////////////////////////////
//same as above, except walks until turn found or maxsteps are reached//
/////////////////////////////////////////////////////////////////////////
procedure walkuntilfindturn(direction,fromside,turndirection,turnfromside:string;maxsteps:integer);
var i:integer;
begin
repeat
i:=i+1;
status('Walking '+direction+' '+inttostr(i)+'/'+inttostr(maxsteps)+' or find '+turndirection+' road');
walkalongsteps(direction,fromside,1);
until((findroad(turndirection,turnfromside))or(i=maxsteps))
status('');
end;

/////////////////////////////////////////////////////////////////////////
//same as above, except walks until color found or maxsteps are reached//
/////////////////////////////////////////////////////////////////////////
procedure walkuntilfindcolor(direction,fromside:string;color,maxsteps:integer);
var i:integer;
begin
repeat
i:=i+1;
status('Walking '+direction+' '+inttostr(i)+'/'+inttostr(maxsteps)+' or color found');
walkalongsteps(direction,fromside,1);
until((roadrunnerfindcolor(color))or(i=maxsteps))
status('');
end;

procedure didwalkingfail(town:string;color:integer);
var fakex,fakey:integer;
begin
if(not(findcolorspiral(fakex,fakey,color,565,5,725,160)))then
begin
writeln(town+' walking failed, ending script');
terminatescript;
end;
end;

procedure fallybanktomine(mappickcolor:integer);
begin
walkalongsteps('S','R',6);
walkuntilfindturn('S','R','W','B',3);
walkuntilfindturn('W','T','S','R',4);
roadrunnerMouse(colorx,colory);
if(not(mappickcolor=0))then
begin
repeat
roadrunnerMouse(648,127);
until(roadrunnerfindcolor(mappickcolor))
roadrunnerMouse(colorx-15,colory-15);
didwalkingfail('fallybanktomine',mappickcolor);
end;
if(mappickcolor=0)then
begin
roadrunnerMouse(648,127);
roadrunnerMouse(648,127);
roadrunnerMouse(648,127);
end;
end;

procedure fallyminetobank(banklogo:integer);
begin
if(not(findroad('N','R')))then
roadrunnerMouse(627,50);
if(findroad('N','R'))then
roadrunnerMouse(colorx,colory);
wait(500+random(200));
roadrunnerflag;
walkuntilfindturn('NE','B','E','B',5);
roadrunnerMouse(colorx,colory);
walkuntilfindturn('E','B','N','L',2);
walkuntilfindcolor('N','R',banklogo,9);
roadrunnerMouse(colorx,colory);
wait(500+random(200));
roadrunnerflag;
didwalkingfail('fallyminetobank',banklogo);
end;

procedure varrockbanktomine(mappickcolor:integer);
begin
walkalongsteps('E','B',1);
walkuntilfindturn('E','B','S','R',3);
if(not(mappickcolor=0))then
begin
walkuntilfindcolor('S','R',mappickcolor,9);
roadrunnerMouse(colorx,colory);
didwalkingfail('varrockbanktomine',mappickcolor);
end;
if(mappickcolor=0)then
begin
walkalongsteps('S','R',6);
end;
end;

procedure varrockminetobank(banklogo:integer);
begin
walkalongsteps('NE','T',1);
walkalongsteps('N','R',2);
walkuntilfindturn('N','R','W','T',8);
walkuntilfindcolor('W','B',banklogo,5);
roadrunnerMouse(colorx,colory);
didwalkingfail('varrockminetobank',banklogo);
end;

procedure ardybanktomine(mappickcolor:integer);
begin
if(findhorizcolor(moparsroadcolor,86,720,654))then
begin
roadrunnerMouse(colorx,colory);
wait(10000+random(500));
roadrunnerantiflag;
roadrunnerflag;
end;
if(not(mappickcolor=0))then
begin
walkalongsteps('NE','B',2);
walkuntilfindcolor('NE','B',mappickcolor,3);
roadrunnerMouse(colorx,colory);
didwalkingfail('ardybanktomine',mappickcolor);
end;
if(mappickcolor=0)then
walkalongsteps('NE','B',4);
end;

procedure ardyminetobank(banklogo:integer);
begin
if(findhorizcolor(moparsroadcolor,80,719,575))then
roadrunnerMouse(colorx,colory);
walkuntilfindcolor('SW','B',banklogo,8);
roadrunnerMouse(colorx+15,colory);
if(findcolorspiral(colorx,colory,banklogo,565,5,725,160))then
roadrunnerMouse(colorx-15,colory);
didwalkingfail('ardyminetobank',banklogo);
end;

edit2:
Actually, it looks like those functions that find colors on a given line might still be helpful today, are there functions that do that in SRL? (or Simba?)

WT-Fakawi

2011-02-04 05:14:40

I have also tons of scripts. All outdated of course, but they are really very good for learning purposes!

Lemme dig them out.


EDIT: Mopar….no, nothing is static colorwise nomore.

grats

2011-02-04 05:32:25

I'm trying to learn about color and how to get all the information & your character to click on the color, if anyone has an old script that can help me with that :P

3Garrett3

2011-02-04 07:54:08

From: Wizzup?
I would like to see where this was decided, as no license was bundled with CStrike's code.


http://villavu.com/forum/showthread.php?t=60896

Hobbit and Cohen said that he needed permission and closed the thread until he got it from CStrike, which hasn't happened yet.