SRL Archive - First Scripts

Bone Collector


Schnauzer

2013-02-03 21:24:02

I thought this section might be more appropriate. But here is my first script, with a combination of a couple tutorials and a my former pascal knowlege I have some up with this bone collector for project 2006:


Program BoneCollecter;
{$I SRL/SRL.Simba}
{$I SRL/SRL/Misc/Debug.Simba}
{$I P06Include/P06Include.Simba}
Const
UPTEXT1 = 'Take B';
UPTEXT2 = 'Take Bo';
UPTEXT3 = 'Take Bon';
UPTEXT4 = 'ake Bone';
UPTEXT5 = 'Take Bones';
UPTEXT6 = 'ake Bones';
UPTEXT7 = 'ke Bones';
UPTEXT8 = 'onze Arr';
UPTEXT9 = 'nze Arro';
Var
Bones:Integer;
Procedure BuryBones;
Var
X,Y:Integer;
Begin
if FindDTM(Bones, x, y, 565, 230, 736, 485) then
Begin
if FindDTM(Bones, x, y, 565, 230, 609, 484) then
Begin
mmouse(x, y, 1, 1);
clickmouse2(mouse_Left);
Wait(RandomRange(250, 400));
End;
if FindDTM(Bones, x, y, 610, 230, 646, 484) then
Begin
mmouse(x, y, 1, 1);
clickmouse2(mouse_Left);
Wait(RandomRange(250, 400));
End;
if FindDTM(Bones, x, y, 645, 230, 698, 484) then
Begin
mmouse(x, y, 1, 1);
clickmouse2(mouse_Left);
Wait(RandomRange(250, 400));
End;
if FindDTM(Bones, x, y, 692, 230, 740, 484) then
Begin
mmouse(x, y, 1, 1);
clickmouse2(mouse_Left);
Wait(RandomRange(250, 400));
End;
End;
repeat
BuryBones;
until
(FindDTM(Bones, x, y, 565, 230, 736, 485)=false)
Exit;
End;
Function GetBoner: Boolean;
Var
tmpCTS,i, L,Counter: Integer;
ObjTPA: TPointArray;
ObjATPA: T2DPointArray;
X,Y,DMCount,Moves: Integer;
Begin
Moves:=0;
DMCount:=0;

tmpCTS := GetToleranceSpeed;
SetColorToleranceSpeed(2);

SetToleranceSpeed2Modifiers(0.16, 0.17);
FindColorsTolerance(ObjTPA, 14013915, 1, 1, 514, 338, 11);
SplitTPAWrap(ObjTPA, 10, ObjATPA);

SortATPASize(ObjATPA,True);
SetColorToleranceSpeed(tmpCTS);
SetToleranceSpeed2Modifiers(0.02, 0.02);

DMCount:=RandomRange(3,5);
L := High(ObjATPA)
MarkTime(Counter);
For i := 0 To L Do
Begin
MiddleTPAEx(ObjATPA[i], X, Y);

Repeat Begin

Moves:=Moves+1;
mmouse(x, y, 1, 1);
Wait(RandomRange(400, 500));
If (P06_IsUpTextMultiCustom([''+ UPTEXT1,''+UPTEXT2, ''+UPTEXT3,''+UPTEXT4,''+UPTEXT5,''+UPTEXT6,''+UPTEXT7,''+UPTEXT8,''+UPTEXT9])) Then
Begin
//P06_ClickCurrent(False);
clickmouse2(mouse_Right);
Wait(RandomRange(200, 500));
P06_ChooseOptionMulti(['Take Bones','ake ones']);
Wait(RandomRange(200, 500));
While IsMoving do
Wait(RandomRange(100, 300));
Exit;
End;
End; Until (Moves > DMCount)
If (TimeFromMark(Counter) > 5000) Then
Begin
Break;
End;
End;
Result:=False;
End;
Procedure Main;
Begin
If (P06_InvFull) Then
Begin
BuryBones;
End;
GetBoner;
End;
Begin
SetupSRL;
SetupP06Include;
MouseSpeed := 17;
Bones := DTMFromString('mWAAAAHicY2FgYPBhYmDwAmIPKJZjZGAQB2JVRgh77qRJDLs2bGBYNnsWw851axn4gXqQMSMaBgEA4EIJuQ==');
GetBoner;
repeat
Main;
Until False;
FreeDTM(Bones);
End.

Sjoe

2013-02-03 22:21:32

Well done on your first script, already got TPAs, . Gotta love em!
Hope to see more from u :p Don't be afraid of the tutorial section, that's where the magic is.

xtrapsp

2013-02-04 07:02:02

Well done, I have a few suggestions though!

  1. You should avoid naming stuff weirdly (Such as UPTEXT1) :)
  2. Let's try moving away from DTM's and moving to TPAs
  3. While we are looking at TPA's it's good to focus on Debugging aswell! (Such as painting on everything it finds).

Tutorials:
http://villavu.com/forum/showthread.php?t=74997
http://villavu.com/forum/showthread.php?t=90767


Once again well done!

rj

2013-02-04 17:40:35

From: xtrapsp
Well done, I have a few suggestions though!

  1. You should avoid naming stuff weirdly (Such as UPTEXT1) :)
  2. Let's try moving away from DTM's and moving to TPAs
  3. While we are looking at TPA's it's good to focus on Debugging aswell! (Such as painting on everything it finds).

Tutorials:
http://villavu.com/forum/showthread.php?t=74997
http://villavu.com/forum/showthread.php?t=90767


Once again well done!

This is my brother that made a account and leaked this, it wasn't even fully operational.

Olly

2013-02-04 18:02:55

From: rjj95
This is my brother that made a account and leaked this, it wasn't even fully operational.

if only I could believe you….

rj

2013-02-04 18:04:18

From: Ollybest
if only I could believe you….


I'm still working on it.. so use it if you want it doesn't work.

I put a password to visit this site and powerbot so he can't troll/make new accounts otherwise if he makes another on here I get banned

Olly

2013-02-04 18:21:15

uh…. you go all emo and quit the day "he" does this….. hmm

rj

2013-02-04 18:27:17

From: Ollybest
uh…. you go all emo and quit the day "he" does this….. hmm


??
I'm not saying the posts I made were his? The account 'Schnauzer' and all the posts by 'Schnauzer' are his, and all the posts by 'RJJ95' are mine. I think your misunderstanding me thinking im accusing him of posting on RJJ95. Oh and he does have another account on here: Thehatered

Ian

2013-02-04 18:28:23

From: rjj95
??
I'm not saying the posts I made were his? The account 'Schnauzer' and all the posts by 'Schnauzer' are his, and all the posts by 'RJJ95' are mine. I think your misunderstanding me thinking im accusing him of posting on RJJ95. Oh and he does have another account on here: Thehatered


No, Olly was saying that you were the one who made the Schauzer acount.

rj

2013-02-04 18:29:48

From: BMWxi
No, Olly was saying that you were the one who made the Schauzer acount.


No.

Justin

2013-02-04 18:55:35

From: rjj95
No.


It's just weird that as soon as you 'rage-quit', the account was created and suddenly had 2 scripts released…

rj

2013-02-04 18:58:14

From: Justin
It's just weird that as soon as you 'rage-quit', the account was created and suddenly had 2 scripts released…


Yes. He has access to the family computer. Therefor all my scripts.

Gucci

2013-02-05 02:43:12

From: rjj95
Yes. He has access to the family computer. Therefor all my scripts.


Yeahhhh sureeee, lol just admit its your account rjj, not like anyone here is going to hate on your for making a second account

rj

2013-02-05 06:27:37

From: Gucci
Yeahhhh sureeee, lol just admit its your account rjj, not like anyone here is going to hate on your for making a second account


Leave me alone it's not my account.