Log in

View Full Version : Ok, please help im new



cepacol2
02-04-2007, 10:46 PM
Im trying to use a chicken killer script. Here it is

/////////////////////////////////////////////////
//// 1.2 ChickenFighter by WhiteShadow ////
/////////////////////////////////////////////////
//// Kills chickens and collects feathers ////
//// Autocolor : Yes ////
//// SRL VER. : SRL 3.2 ////
/////////////////////////////////////////////////
//// Stand in Chicken pen in South Falador ////
//// 3 piece armor just in case of randoms ////
//// Have a feathers in first inventory slot ////
//// Set DeclarePlayers; and const ////
//// Start script logged out to decrease lag ////
/////////////////////////////////////////////////
//// History ////
//// v.1.0 - First released ////
//// v.1.1 - Fixed Chicken Killing ////
//// v.1.2 - Some callibration changes ////
/////////////////////////////////////////////////

program ChickenFighter;
{.include SRL\SRL.Scar}
{.include SRL\SRL\Skill\Fighting.Scar}

var
Chicken : array[0..2] of Integer;
FeatherDTM, DisPlay, MMWater, Killz : Integer;
SwitchMark, IntTime, TakeCount, CaMark : Integer;

const
iPlay = 10; //# of minutes until switch player
StartPlayer = 0; //Player to Play first.
Extensive = True; //For long individual player reports.
GambleBox = True; //Set to true if your computer lags when it solves NewBox
WaitChick = 4000; //Miliseconds until next chicken click. + random(1000)
CalTime = 60000; //Miliseconds to walk back to center.

procedure DeclarePlayers;
begin
HowManyPlayers:= 4;
NumberOfPlayers(HowManyPlayers);

Players[0].Name :='';
Players[0].Pass :='';
Players[0].Nick :='';
Players[0].Integer1 := 1; //1 - 4 fightmode.
Players[0].Active := True;

Players[1].Name :='';
Players[1].Pass :='';
Players[1].Nick :='';
Players[1].Integer1 := 1; //1 - 4 fightmode.
Players[1].Active := True;

Players[2].Name :='';
Players[2].Pass :='';
Players[2].Nick :='';
Players[2].Integer1 := 1; //1 - 4 fightmode.
Players[2].Active := True;

Players[3].Name :='';
Players[3].Pass :='';
Players[3].Nick :='';
Players[3].Integer1 := 1; //1 - 4 fightmode.
Players[3].Active := True;

end;

procedure LoadAll ;
begin

Chicken[0]:= 1121675;

Chicken[1]:= 2160891;

Chicken[2]:= 858759;

FeatherDTM:= DTMFromString('78DA63F466626078C200062C108A61F1B4A 90' +
'CFF81342310FF07024647A09A2F0C6880118904D20140354F 09A8' +
'7102AA794C404D3050CD35FC6A00784D0CCD');

MMWater := BitmapFromString(2, 2, '6277A56277A56277A56277A5');

end;

function Convert0r : String;
begin
case Players[CurrentPlayer].Integer1 of
1 : Result:= 'attack';
2 : Result:= 'strength';
3 : Result:= 'hitpoints';
4 : Result:= 'defence';
end;
end;

procedure NoBannage;
begin
RotateEvery(4 + random(3));
LeaveScreenEvery(5 + random(5));
HoverEvery(8 + random(4), Convert0r);
PickUpMouseEvery(5 + random(10));
RandomRClickEvery(15 + random(5));
end;

function FindRandoms : Boolean;
var
i: Integer;
begin
for i := 1 to 17 do
begin
case I of
1: CloseWindow;
2: if FindTalk then
Result := True;
3: if FindDead then
Result := True;
4: if FindMod then
Result := True;
5: if FindMime then
Result := True;
6: if FindMaze then
Result := True;
7: if FindQuiz then
Result := True;
8: if FindDemon then
Result := True;
9: if FindScapeRune then
Result := True;
10: if FindTalk then // Call it twice
Result := True;
11: if FindLamp(LampSkill) then // Maybe we missed it?
Result := True;
12: if (FindNewBox) then
begin
Result := True;
if(GambleBox = True)then
begin
if(not(GambleNewBox))then
LogOut;
end else
SolveBox;
end;
13: if FindTrade then
Result := True;
14: begin
if NoGameTab then
begin
if ( SolveFrog ) then Exit;
Result := True;
Players[CurrentPlayer].loc := 'No GameTab';
Logout;
Exit;
end;
end;
15: SaveToChatLog;
16: if SolvePinball then
Result := True;
17: NoBannage;
end;
wait(1);
end;
end;

procedure RandClick(x, y : Integer);
begin
if(random(3) = 0)then
begin
Mouse(x, y, 1, 1, false);
end else
Mouse(x, y, 0, 0, true);
end;

procedure FindWait(Ms, R : Integer);//Wait with randoms.
var
WaitTime, DivTime, i : Integer;
begin
WaitTime:= Ms + random(r);
DivTime:= Trunc(WaitTime div 3);
repeat
Wait(DivTime - round(r div 4));
FindRandoms;
if(random(24) = 2)then
SendArrowSilentWait(random(3), 300 + random(200));//Humans tilt alot?
i:= i + 1;
until(i >= 3);
end;



function FindChicken : Boolean;
var
i, v: Integer;
begin
if(not(LoggedIn))then
Exit;
repeat
if(InFight)then
Result:= True;
if(Result = True)then
Exit;
FindRandoms;
v:= v + 1;
i:= random(2);
if(FindObj(x, y, 'hick', Chicken[i], 10))then
begin
RandClick(x, y);
ChooseOption(x, y, 'Attack');
Flag;
FindWait(3000, 1000);
Flag;
if(InFight)then
Result:= True;
FindTalk;
end;
if(not(LoggedIn))then Exit;
until(Result = True) or (v > 7)
end;

procedure FightWait;
var
Mark3 : Integer;
begin
if(not(InFight))then Exit;
MarkTime(Mark3);
repeat
Wait(100);
FindRandoms;
if(not(LoggedIn))then Break;
FindTalk;
until(TimeFromMark(Mark3) >= WaitChick + random(1000)) or (not(InFight))
Killz:= Killz + 1;
end;

function CollectItems : Boolean;
var
a : TPoint;
c : Integer;
begin
repeat
c:= c + 1;
if(not(LoggedIn))then Exit;
FindRandoms;
if(FindColorTolerance(a.x, a.y, 7632531, Msx1, Msy1, Msx2, Msy2, 10))or
(FindColorTolerance(a.x, a.y, 10240, Msx1, Msy1, Msx2, Msy2, 10))then
begin
MMouse(a.x, a.y, 0, 0);
if(IsUpText('ake'))then
begin
Result:= True;
Mouse(a.x, a.y, 2, 2, false);
if(ClickOption('eather', 1))then
TakeCount:= TakeCount + 1;
Flag;
if(InvCount < 28)then
if ChooseOption(x, y, 'hick') then
TakeCount:= TakeCount + 1;
Flag;
end;
end;
until(InvFull) or (c > 2)
end;

procedure MSC;
begin
Writeln('Mouse adjust');
if(random(2) = 0)then
MouseSpeed:= 8 + random(3)
else
MouseSpeed:= 6 + random(4);
BenMouse:= True;
SetTimeOut(60, 'MSC');
Status('');
end;

procedure LoadScript;
begin
ClearDebug;
SetUpSRL;
LoadAll;
DeclarePlayers;
CurrentPlayer:= StartPlayer;
BenMouse:= True;
MouseSpeed:= 7;
if(not(LoggedIn))then
LoginPlayer;
MSC;
end;

procedure xPosition; //anti lost.
begin
if(TimeFromMark(CaMark) > CalTime)then
begin
MarkTime(CaMark);
MakeCompass('N');
if(random(2) = 0)then
begin
SymbolAccuracy:= 0.4;
if(FindSymbol(x, y, 'churn'))then
MouseFlag(x - 25, y + 5, 5, 5);
end else
begin
if(FindBitmapToleranceIn(MMWater, x, y, Mmx1, Mmy1, Mmx2, Mmy2, 50))then
MouseFlag(x + 1, y - 23, 2, 2);
end;
end;
end;

procedure PlayerStats;
var
PSActive : String;
i : Integer;
begin
for i := 0 to HowManyPlayers-1 do
begin
if(Players[i].Active = True)then
PSActive:='True'
else
PSActive:='False';
Writeln('#'+IntToStr(i)+' : '+Players[i].name+ ', Active = '+PSActive+', Feathers = '+IntToStr(Players[i].Banked));
end
writeln('<---------------------------------------------->');
end;

procedure Report;
begin
ClearDebug;
Writeln('<---------------------------------------------->');
Writeln(' Chicken Fighter v.1.0 by WhiteShadow ');
Writeln(' Worked For '+ScriptTime2(2));
Writeln(' Killed '+IntToStr(Killz)+' chickens ');
Writeln(' Collected '+IntToStr(TakeCount)+ ' times');
Writeln('<---------------------------------------------->');
if(Extensive = True)then
PlayerStats;
end;

begin
LoadScript;
NickNameBMP:= CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
repeat
if(not(FindDtm(FeatherDTM, x, y, 564, 211, 606, 249)))then
begin
Writeln('ahmmph, feathers in 1st inventory slot!');
Writeln('God read the freaking directions!');
LogOut;
Players[CurrentPlayer].Active:= False;
end;
if(LoggedIn)then
begin
ChatsOff;
SetFightMode(Players[CurrentPlayer].Integer1);
SetRun(True);
GameTab(4);
HighestAngle;
IntTime:= (iPlay * 60000) + random(5 * 60000);
Display:= Round(IntTime / 60000);
Writeln(Players[CurrentPlayer].Name+' will play '+IntToStr(DisPlay)+' minutes');
MarkTime(SwitchMark);
end;
MarkTime(CaMark);
repeat
FindChicken;
Wait(50 + random(50));
FightWait;
Wait(50 + random(50));
CollectItems;
CountInvSlot(Players[CurrentPlayer].Banked, 1, 1);
if(not(LoggedIn))then
Break;
xPosition;
CollectItems;
Report;
until(TimeFromMark(SwitchMark) > IntTime)

if(LoggedIn)then
NextPlayer(True);

if(not(LoggedIn))then
NextPlayer(False);

until(False)
end.



What do I do with it, and what are the purple areas? Sorry for being so dumb. im already at fally south chicken pen, but now i have no clue. Please help. Thnx

bullzeye95
02-04-2007, 10:55 PM
We're not going to help you with that! Go learn SCAR!

cepacol2
02-04-2007, 10:58 PM
how can i, if no one helps me? im not a dum ass, im comp savy, i hack maplestory, using debugger, packet editing, ect. -.-. please just help, so i can understand and help contribute by making scripts.

Fearlesssss
05-04-2007, 11:03 AM
OMG... 1. Never post some1's script into a post.
2. Go to tutorial island and read the tuts so you can learn how to work
with scar.
3. And don't just say help when you have done no research. First try
to learn in the tutorial island section and if you after that don't
know sometin you can always ask and you will get an answer. And
explain your question better.

me_ntal
05-04-2007, 12:30 PM
Ok than ill teach you a few things, first when posting a script use the [scar] tags
2nd to run a script drag the crosshairs onto the runescape client
3rd fill in the detials such as the player username and password
4th press the little green arrow

Any trouble first refer to the following guide http://www.srl-forums.com/forum/auto-properly-dummies-p100085.html#post100085

Harry
10-28-2007, 02:56 PM
05-04-2007, 08:30 AM

Stop bumping old topics please..
and http://www.srl-forums.com/forum/customavatars/avatar66_1.gif <-- Thanks solemn :)