SRL Archive - Simba (Testing) Scripts

[In progress] EmScript


Emaziz

2010-07-31 17:34:03

EmScript

Well, I find walking scripts awesome. So I decided to make my own! :thumbsup:

My final goal is to make this script support several skills stuff to do, but my main goal is to make an awesome walking script being able to walk perfectly to any location by only entering one function!

EDIT:
I've learned a lot about walking by writing this, and therefore I will rewrite the whole shit into an efficient script with possibilities to walk to banks and such without too much trash variables, so expect a pure walking script soon :spot:

Old (incomplete but walking in alkharid works) script is still uploaded if anyone cares to check it out :P

i luffs yeww

2010-07-31 17:53:50

Huh. I never even knew there was a "ClickMouse2." :p

Looks good so far. Standards are a bit off, but no biggie.

Heavenguard

2010-07-31 23:14:35

Nice! First time iv seen a person tackle walking head on as a script. great job dude.

Gu3st...

2010-08-01 10:54:02

Cool, Another walker :)
I love these myself, and I made one too. I used color though, and it's capable of walking to anywhere in the (free) runescape world. Check it out!

function Walker_IsMapUp : Boolean;
var tmp : String;
begin
Result := GetMMLevels('hp', tmp) = -1;
end;

procedure Walker_CloseMap;
var T : Integer;
begin
Mouse(746, 15, 4, 4, True);
Wait(2000);
T := GetSystemTime + 15000;
while (GetSystemTime < T) do
begin
if not Walker_IsMapUp then Exit;
Wait(200+Random(500));
SleepAndMoveMouse(100+Random(1000));
end;
end;

function Walker_OpenWorldmap : Boolean;
var T : Integer;
begin
Result := Walker_IsMapUp;
if Result then Exit;
MouseBox(527, 139, 559, 156, 1);
Wait(1500);
T := GetSystemTime + 15000;
while (GetColor(230, 196) = 1118604) and (GetSystemTime < T) do
begin
Wait(500+Random(1500));
SleepAndMoveMouse(500+Random(1500));
end;
Result := GetSystemTime < T;
end;

procedure Walker_GetPos(var X, Y : Integer);
begin
if Walker_OpenWorldmap then
begin
MouseBox(666, 469, 698, 491, 1);
FindColor(X, Y, 255, 609, 311, 757, 460);
if X + Y > 1 then
begin
X := X - 608;
Y := Y - 310;
end;
end;
end;

procedure Flag;
begin
while IsMoving do
if (FlagDistance < 20) and (FlagDistance > 0) then Break;
end;

function Walker_Walk(Loc : TPoint) : Boolean;
var
MapDist, I : Integer;
Angle, FAngle : Extended;
WalkPoint, Cur : TPoint;
begin
Walker_GetPos(Cur.X, Cur.Y);
Walker_CloseMap;

MapDist := Distance(Cur.X, Cur.Y, Loc.X, Loc.Y);
Angle := Degrees(ArcTan2(Cur.Y - Loc.Y, Cur.X - Loc.X));
Angle := Angle + 180;
if Angle > 360 then Angle := Angle - 360;

for I := 1 to MapDist do
begin
FAngle := Angle - rs_GetCompassAngleDegrees;
WalkPoint := RotatePoint(Point(MMCX + 60, MMCY), Radians(FAngle), MMCX, MMCY);
Mouse(WalkPoint.X-2, WalkPoint.Y-2, 4, 4, True);
if Random(3) = 0 then
MouseBox(MMX1, MMY1, MMX2, MMY2, 3);
RunEnergy(30);
Flag;
Wait(150);
end;

while IsMoving do
Wait(100);

Result := True;
end;

function Walker_WalkTo(SearchString : String) : Boolean;
var
TargetPos : TPoint;
begin
if Walker_OpenWorldmap then
begin
MouseBox(98, 472, 320, 487, 1);
TypeSend(SearchString);
Wait(1000+Random(500));
Walker_GetPos(TargetPos.X, TargetPos.Y);
end;

Result := Walker_Walk(TargetPos);
end;

I don't know if it works anymore, but it can't be that hard to fix, as it only took me a couple of minutes to figure out how to do it

Good luck! ^^,

Emaziz

2010-08-01 13:30:04

From: Zyt3x
Cool, Another walker :)
I love these myself, and I made one too. I used color though, and it's capable of walking to anywhere in the (free) runescape world. Check it out!

I don't know if it works anymore, but it can't be that hard to fix, as it only took me a couple of minutes to figure out how to do it

Good luck! ^^,


At the moment both my accounts (I don't care for an army >_<) are busy, but I'm looking forward to try it. How often does it open world map?

Gu3st...

2010-08-01 18:48:47

From: Emaziz
At the moment both my accounts (I don't care for an army >_<) are busy, but I'm looking forward to try it. How often does it open world map?
I think once, maximum twice :)

Here is a old version in-game: http://www.youtube.com/watch?v=-lyzYBmrwF8

dhandley12

2010-09-25 23:09:08

I just tried running your script and It successfully compiled but when runescape loaded after it logged me in it stopped working and in command prompt I got the error message:

Field not found: <= bj.x, s, l, naa.p, etc…
WARNING in native method: Jni call made with exception pending
WARNING in native method: Jni call made with exception pending

Not sure if this is me missing some user information in the script or not but I just thought I would tell you. I know this is a work in progress and hope this is somehow helpful.

Wyn

2010-09-25 23:19:58

From: dhandley12
I just tried running your script and It successfully compiled but when runescape loaded after it logged me in it stopped working and in command prompt I got the error message:

Field not found: <= bj.x, s, l, naa.p, etc…
WARNING in native method: Jni call made with exception pending
WARNING in native method: Jni call made with exception pending

Not sure if this is me missing some user information in the script or not but I just thought I would tell you. I know this is a work in progress and hope this is somehow helpful.


Go get #621.

dhandley12

2010-09-25 23:22:27

what do you mean by that? Sorry I'm a newbie and easily confused.