SRL Archive - First Scripts

Rwj4reals Autofighter


rwj4real

2009-02-15 14:09:12

{ Rwj4real's Autofight
{------------------------
{ I am in need of a proggy script!! I will give credit!!!
{------------------------
{ BUGS----
{ Has a slow startup loading smart - Prolly Easy Fix
{
{ Gets Colors mixxed up - Will happily give credit to anyone who helps
{
{ Has no proggress report!!!! - Working on one but will be appreciated if someone submits one to me!!
{------------------------
{ Need To Knows -----
{ Fill Out Lines 30 Through 50
{ Have Smart!!!
{------------------------
{Once Again
{THANK YOU!!
{------------------------

This script will fight for you just put in the colors.


THIS IS SMART!!!!
I WILL RELEASE A SECOND VERSION LATER
IT WILL INCLUDE A NON SMART VERSION



1.1————
Has a new color detecting script
:)

Less color mixupps

ian.

2009-02-15 16:18:05

procedure AntiBan;
begin

case (Random(30)) of
1: RandomRClick;
1: HoverSkill('Woodcutting', False);
1: HoverSkill('Mining', False);
1: HoverSkill('Runecrafting', False);
1: HoverSkill('Magic', False);
1: HoverSkill('Smithing', False);
1: HoverSkill('Strength', False);
1: HoverSkill('Attack', False);
1: HoverSkill('Defence', False);
1: HoverSkill('Hitpoints', False);
1: HoverSkill('Firemaking', False);
1: HoverSkill('Crafting', False);
2: RandomMovement;
2: BoredHuman;
2: DoEmote(400 +Random(90));
2: PickUpMouse;
4: begin
Gametab(1 + Random(12));
Wait(3000 + Random(2000));
Gametab(4);
end;
30: SleepAndMoveMouse(3600);
end;
end;

errr.. that seems kinda weird to me.. :p bad cases.. not sure, but won't it do all of the case 1 if it gets 1 for the case?

rwj4real

2009-02-15 20:12:29

Huh Good point must have overlooked that!
Thanks:o

Holy Nites

2009-02-16 12:45:05

I'm still stumped at how you get the colour of a chicken! :(

Skippz

2009-02-16 13:19:45

From: Holy Nites
I'm still stumped at how you get the colour of a chicken! :(


At the top of the SCAR screen there is a picture that resembles a medicine dropper, if you hover over it it should say Color Picker. Click that picture and your screen will pause and it should show a cross hair with a color diagram by it, drag the cross hair over the chicken or any other monster and click. Then at the bottom of SCAR you'll see something like "Color Picked: 15525862 at (32, -5)" Then just copy and paste the numbers after the Color picked part into the script :D.

Kasi

2009-02-16 13:30:32


procedure AntiBan;
begin
case (Random(30)) of
1 : RandomRClick;
2 : HoverSkill(Random, False);
3 : RandomMovement;
4 : BoredHuman;
5 : DoEmote(400 +Random(90));
6 : PickUpMouse;
7 : begin
Gametab(1 + Random(12));
Wait(3000 + Random(2000));
Gametab(4);
end;
8 : SleepAndMoveMouse(3600);
end;
end;

u can use random as a hoverskill to and what would have been wrong with that and if u put like 2 1's and 1 is chosen then it will only do the 1 declared first e.g


1 : RandomRClick;
1 : HoverSkill(Random, False);

it will only do randomRclick since it was the first declared at least thats what i think

Kasi

2009-02-16 13:46:08


program AutoFighter;
{------------------------
{ Rwj4real's Autofight
{------------------------
{ I am in need of a proggy script!! I will give credit!!!
{------------------------
{ BUGS----
{ Has a slow startup loading smart - Prolly Easy Fix
{
{ Gets Colors mixxed up - Will happily give credit to anyone who helps
{
{ Has no proggress report!!!! - Working on one but will be appreciated if someone submits one to me!!
{------------------------
{ Need To Knows -----
{ Fill Out Lines 33 Through 52
{ Have Smart!!!
{------------------------
{Once Again
{THANK YOU!!
{---------------------------------------------------------------------------------------------------------------------------------------}


{---------------------------------}
{.Include SRL\SRL\Misc\SMART.SCAR}
{.Include SRL\SRL.SCAR}
{.include SRL/SRL/misc/Users.scar}
{---------------------------------}

var
x, y: Integer;
MonsterColor : TIntegerArray;
MonsterName : TStringArray;

Const
MySRLID = '7123';//example: '9999'
MySRLPassword = '147852369';//example: 'password'

procedure Playersetup;
Begin
HowManyPlayers := 1;//Change this accordingly
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;

MonsterColor := [12370117, 5528425, 5863579]; // Colors have as many as u want
MonsterName := ['Co', 'ow']; // Names have as many as u want

Players[0].Name :=''; //Character Name
Players[0].Pass :=''; //Character Pass
Players[0].Nick :=''; //Nickname 3 - 4 Letter's of char name
Players[0].Active := True; //True if you want this player to be ran in the script, false if not

{_______________________________________________________________________________________________________________________________
{Dont Change Below Here
{___________________________________________________________________________________________________________________________________________}
LoginPlayer;
SRLid:= MySRLId;
SRLpassword:= MySRLPassword;
SendSRLReport;
Wait(2000 + random(1000));
SetAngle(True);
MakeCompass('n');
Setrun(True);
end;

Procedure Startup;
Begin
/// SMARTSetupEx(2, False, True, False);
/// Wait(5000);
/// SetTargetDC(SmartGetDC);
/// repeat
/// wait(100);
/// until(SmartGetColor(253, 233)<>1118604);
SetUpSRL;
End;

procedure Report;
begin
cleardebug;
writeln('Rwj4reals Autofight');
writeln('');
writeln('You been running this Autofighter for' + TimeRunning);
writeln('The time right now is: ' +TheTime);
end;

Procedure Sig;
Begin
ClearDebug;
Writeln(' Thank you!!!');
Wait(200);
Writeln(' I need a Proggy script so if you can make one it would be appreciated!');
Wait(200);
Writeln(' Giving credit!!!!');
End;

procedure AntiBan;
begin
case (RandomRange(1, 9)) of
1 : RandomRClick;
2 : HoverSkill('Random', False);
3 : RandomMovement;
4 : BoredHuman;
5 : DoEmote(400 +Random(90));
6 : PickUpMouse;
7 : Gametab(1 + Random(12));
8 : SleepAndMoveMouse(3600);
end;
end;

procedure Kill;
begin
if not LoggedIn then exit;
FindNormalRandoms;
if FindObjCustom(x, y, [MonsterName], [MonsterColor], 10) then
Begin
WriteLn('Killing');
Mouse(x, y, 2, 2, False);
Wait(900 + Random(110));
if not ChooseOption('ttack') then Exit;
FFlag(0);
Repeat
If FindFight Then AntiBan;
Until(Not FindFight Or (HPPercent < 25));
If (HPPercent < 25) then RunTo('N', true);
GameTab(4);
End;
end;

Begin
Sig;
Startup;
Playersetup;
Repeat
Kill;
Wait(2000);
Report;
Until(not LoggedIn);
if not LoggedIn then
LoginPlayer;
Antiban;
FindNormalRandoms;
Repeat
Kill;
Until(Not LoggedIn);
end.

i fixed some of it up for u

Tickyy

2009-02-16 17:06:44

From: Holy Nites
I'm still stumped at how you get the colour of a chicken! :(


Read my tut : All About Colors