SRL Archive - OSR Help

Lodestone teleport function


ssshhhaaa

2012-04-19 09:48:07

Im having trouble using the lodestone teleport in my script.

Here is the function:

function LodestoneTeleport(Where: String): Boolean;

i know how to use it, but it when ive placed it into my script it doesnt click he home teleport and tele.

If there is anyone who knows how to use this help me :)?

Gucci

2012-04-19 10:24:15

Can you show the part of the code where that is? Also is you location string one of the proper options?

Olly

2012-04-19 12:29:00

Pretty sure lodestone teleport will only do the teleport screen, so you will have to click home tele. And you need to add Lodestoneteleport('Lumbridge'); or where ever your teleporting to.

ssshhhaaa

2012-04-19 14:46:39

From: Ollybest
Pretty sure lodestone teleport will only do the teleport screen, so you will have to click home tele. And you need to add Lodestoneteleport('Lumbridge'); or where ever your teleporting to.


Oh my gawd, so thats why it wasnt doing it :surprised:

Do you know of any function that will click on the home teleport button?

Element17

2012-04-19 16:32:54

Try something like this?

Procedure TeleHome;
Var
TeleDTM: Integer;
Begin
GameTab(Tab_Magic);
If FindDTM(TeleDTM, x, y, MIX1, MIY1, MIX2, MIY2) Then
Begin
MMouse(x, y, 0, 0);
Wait(500);
if IsUpText('Cast') then
begin
Mouse(X, Y, 0, 0, false);
Wait(500);
End;

Make your own DTM and read tuts on how to and how to put them in your script.

ssshhhaaa

2012-04-20 06:39:04

Thanks for you helps guys, ive progressed quite a bit but im still having problems with actually clicking the lumbridge teleport sign after the lodestone screen has opened.

Heres my script so far :


program new;
{$DEFINE SMART}
{$i srl/srl.simba}
{$i sps/sps.simba}
{$i ObjectDTM\ObjDTMInclude.simba}

var
x, y, Home:Integer;
begin
Smart_Server := 10;
Smart_Members := True;
Smart_Signed := True;
ClearDebug;
SetupSRL;

Home := DTMFromString('mwQAAAHic42RgYLBjYmBwZoLQllDaBcq2AmJHIH7KAMGvoPR9IH4BxC+B+CEQPwDifUc+Mfho1jM4KCWD6UKvIobiosMMWZEHGIIDQsGYH6iOEGYkAsMBAIEUFk0=');

GameTab(Tab_Magic);

If FindDTM(Home, x, y, MIX1, MIY1, MIX2, MIY2) Then
Begin
MMouse(x, y, 0, 0);
Wait(500);
end;
FreeDTM(Home);
if IsUpText('Cast') then
begin
Mouse(X, Y, 0, 0, false);
Wait(500);
WaitOption ('Cast', 3000)
end;

Lodestoneteleport('Lumbridge')

end.

Element17

2012-04-20 09:21:03

What is it doing? What is it not doing?

ReadySteadyGo

2012-04-20 09:58:20

function EdgevilleHomeTele: Boolean; // Xtrapsp and ReadySteadyGo
var
HomeTele, x, y: Integer;
begin
Result := False;
if not GameTab(tab_Magic) then
Exit;
HomeTele := DTMFromString('mggAAAHicY2NgYNjGxMCwiQlBrwbinUD8Gyj3H4pB7L8w/Pcvw74jn8AYxG6bc4PBR7OeQRIohw0z4sAQAADcGhiV');
if FindDTM(HomeTele, x, y, MIX1, MIY1, MIX2, MIY2) then
begin
MMouse(x, y, 3, 3);
if WaitUptext('ome', 1000) then
begin
ClickMouse2(mouse_Left);
if WaitFunc(@LodestoneScreen, 250, 4000) then
Result := LodestoneTeleport('Edgeville');
Wait(RandomRange(1200, 1500));
if LodestoneScreen then
begin
ClickMouse2(mouse_Left);
Wait(RandomRange(600, 900));
Result := not LodestoneScreen;
end;
end;
end;
FreeDTM(HomeTele);
end;

I had issues with it too, there are problems with the function itself due to wait times. I will make a fix to the actual function at some point but I was in a rush to get it working.

Code above should be fine, just change to lumbridge.

Home

2012-04-20 10:27:46

I'm not sure if Jagex changed something after I made that function. If no fix have been made by tomorrow. I will give it a shot :)


~Home

ssshhhaaa

2012-04-20 14:21:57

I just noticed something. If you have a script that only needs to go to one destination, instead of opening up the lodestone screen and clicking on the lumbridge sign it's much easier if you right click the home teleport sign and choose previous destination ;]

Saves alot of time and space in the script, was kinda amazed when i found it ;]


ReadySteadyGo

2012-04-24 15:29:32

From: ssshhhaaa
I just noticed something. If you have a script that only needs to go to one destination, instead of opening up the lodestone screen and clicking on the lumbridge sign it's much easier if you right click the home teleport sign and choose previous destination ;]

Saves alot of time and space in the script, was kinda amazed when i found it ;]



This is awesome, can't believe I didn't notice it. Thanks!

ssshhhaaa

2012-04-24 16:32:25

From: ReadySteadyGo
This is awesome, can't believe I didn't notice it. Thanks!


No problem :)