Jump to content

Recommended Posts

Posted

Hello guys i have a script for Ketra to farm some molars.. im trying to create a new script for FoG lower lvl teleport, but it uses a nobles teleport.

 

I made this setup for the script:

 

 

if user.inrange(148019,-55501,-2759, 700) then begin
   Engine.FaceControl(0,false);
  Engine.MoveTo(148012, -55745, -2751);
  Engine.SetTarget(31360);
  Engine.DlgOpen;
  Delay(500);
  Engine.DlgSel(13);
  Delay(500);
  Engine.MoveTo(147759, -55452, -2759);
  Engine.MoveTo(147979, -55282, -2759);
  delay(500);
  Engine.SetTarget('Tatiana');
  Engine.DlgOpen;
  delay(500);
  engine.dlgsel(4);
  delay(500);
  engine.dlgsel(2);
  delay(500);
  engine.dlgsel(12);
  delay(500);
  engine.dlgsel(1);
  Engine.CancelTarget;
  delay(500);
 
After the yellow line, he doesn't follow the script, he doesn't click the line: "Do not use nobless gate pass". He just backs to npc buff.
 
Heres the whole script i made:
 
                  uses sysutils;
 
procedure buff;
 
var
buff1: TL2Effect;
item: TL2Item;
function CheckBuff: Boolean;
begin
    if not User.Buffs.ByID(1085, buff1) then begin
                  engine.useitem(736);
  delay(30000);
        Result:=false;
        Print('Buffs are needed. Buffing...');
  Engine.MoveTo(147725,-56170,-2807);
  Engine.MoveTo(148031,-55527,-2759);
 Engine.SetTarget('La2Dream');
Engine.DlgOpen;
Engine.DlgSel(5);
Delay(500);
 
end;Engine.MoveTo(43892, -48345, -792);
Result:=true;
end;
 
///////////////////////////////////////////////////////////
 
function deadCheck: Boolean;
begin
Result := false;
    if User.Dead then begin
        Result := true;
        Print('Dead. Pressing to village.');
        Delay(1000);
        Engine.GoHome;
        Delay(1000);
    end
    else
    begin
     Delay(5000);
    end;
    end;
///////////////////////////////////////////////////////////
 
       begin
 while true do begin
 deadcheck;
         
 
 
 
 
        
   if user.inrange(144942, -55390, -3007, 250, 150) then begin
   Engine.MoveTo(145236, -56823, -3007);
   Engine.MoveTo(145574, -56834, -3007);
   Engine.MoveTo(146285, -56405, -2807);
   Engine.MoveTo(147627, -56010, -2799);
   Engine.MoveTo(147938, -55476, -2759);
   end;
 
 
 
  //////////////////////////////
 
if user.inrange(146272, -58176, -2976, 250, 150) then begin
Engine.MoveTo(147593, -58103, -3007);
Engine.MoveTo(147727, -57141, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(145264, -57680, -2976, 250, 150) then begin
Engine.MoveTo(145588, -56926, -3007);
Engine.MoveTo(146673, -56095, -2807);
Engine.MoveTo(147543, -56054, -2807);
Engine.MoveTo(148012, -55745, -2751);  
    end;  
if user.inrange(145696, -57696, -2976, 250, 150) then begin
Engine.MoveTo(145510, -56930, -3007);
Engine.MoveTo(146499, -56202, -2807);
Engine.MoveTo(147481, -56031, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(144944, -55392, -2976, 250, 150) then begin
Engine.MoveTo(145153, -56813, -3007);
Engine.MoveTo(145569, -56855, -3007);
Engine.MoveTo(146467, -56271, -2807);
Engine.MoveTo(147566, -56034, -2807);
Engine.MoveTo(148012, -55745, -2751);   
    end;  
if user.inrange(144752, -56752, -2976, 250, 150) then begin
Engine.MoveTo(145534, -56884, -3007);
Engine.MoveTo(146265, -56418, -2807);
Engine.MoveTo(147407, -56063, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(149120, -58064, -2976, 250, 150) then begin
Engine.MoveTo(147706, -58107, -3007);
Engine.MoveTo(147751, -56737, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(150400, -56752, -2976, 250, 150) then begin
Engine.MoveTo(149935, -56870, -3007);
Engine.MoveTo(149139, -56390, -2807);
Engine.MoveTo(147929, -56063, -2807);
Engine.MoveTo(148012, -55745, -2751);   
    end;  
if user.inrange(150704, -55744, -2976, 250, 150) then begin
Engine.MoveTo(149935, -56870, -3007);
Engine.MoveTo(149139, -56390, -2807);
Engine.MoveTo(147929, -56063, -2807);
Engine.MoveTo(148012, -55745, -2751);   
    end;  
if user.inrange(147680, -58208, -2976, 250, 150) then begin
Engine.MoveTo(147727, -57141, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(148288, -58304, -2976, 250, 150) then begin
Engine.MoveTo(147738, -58050, -3007);
Engine.MoveTo(147727, -57141, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(147232, -58480, -2976, 250, 150) then begin
Engine.MoveTo(147677, -58063, -3007);
Engine.MoveTo(147727, -57141, -2807);
 Engine.MoveTo(148012, -55745, -2751);
    end;  
if user.inrange(149088, -56256, -2776, 250, 150) then begin
Engine.MoveTo(147854, -56054, -2807);
Engine.MoveTo(148012, -55745, -2751);   
    end;
if user.inrange(146832, -55904, -2776, 250, 150) then begin
Engine.MoveTo(147529, -56046, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(146368, -56256, -2776, 250, 150) then begin
Engine.MoveTo(147529, -56046, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(147664, -56464, -2776, 250, 150) then begin
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(147680, -56928, -2776, 250, 150) then begin
Engine.MoveTo(147810, -56110, -2807);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(148560, -55904, -2776, 250, 150) then begin
Engine.MoveTo(148012, -55745, -2751);
    end;
    if user.inrange(149872, -57424, -2976, 250, 150) then begin
Engine.MoveTo(149897, -56910, -2979);
Engine.MoveTo(149230, -56412, -2779);
Engine.MoveTo(147939, -55999, -2772);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(144960, -56224, -2976, 250, 150) then begin
Engine.MoveTo(145458, -56853, -2979);
Engine.MoveTo(146343, -56326, -2779);
Engine.MoveTo(147625, -55995, -2772);
Engine.MoveTo(148012, -55745, -2751);
    end;   
if user.inrange(144496, -55088, -2976, 250, 150) then begin
Engine.MoveTo(145327, -56873, -2979);
Engine.MoveTo(146337, -56445, -2779);
Engine.MoveTo(147533, -55963, -2766);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(145392, -56960, -2976, 250, 150) then begin
Engine.MoveTo(146347, -56305, -2779);
Engine.MoveTo(147514, -56003, -2772);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(150238, -57165, -3002, 250, 150) then begin
Engine.MoveTo(149051, -56361, -2782);
Engine.MoveTo(147790, -56080, -2782);
Engine.MoveTo(148012, -55745, -2751);
    end;
if user.inrange(149088, -56256, -2776, 250, 150) then begin
Engine.MoveTo(147711, -55910, -2752);
    end;  
 
///////////////////////////////////////////////////////////  
 
  if user.inrange(148019,-55501,-2759, 700) then begin
   Engine.FaceControl(0,false);
  Engine.MoveTo(148012, -55745, -2751);
  Engine.SetTarget(31360);
  Engine.DlgOpen;
  Delay(500);
  Engine.DlgSel(13);
  Delay(500);
  Engine.MoveTo(147759, -55452, -2759);
  Engine.MoveTo(147979, -55282, -2759);
  delay(500);
  Engine.SetTarget('Tatiana');
  Engine.DlgOpen;
  delay(500);
  engine.dlgsel(4);
  delay(500);
  engine.dlgsel(2);
  delay(500);
  engine.dlgsel(12);
  delay(500);
  engine.dlgsel(1);
  Engine.CancelTarget;
  delay(500);
if user.inrange(179886, -111224, -5819, 1000)
 then begin
 print('Moveing to spawn');
    Engine.MoveTo(179731, -112055, -5832);
    Engine.MoveTo(177781, -112378, -5832);
    Engine.MoveTo(177146, -112445, -5709);
    Engine.MoveTo(176555, -112202, -5533);
    Engine.MoveTo(174712, -112184, -5472);
    Engine.MoveTo(174712, -112168, -5472);
    Engine.MoveTo(174696, -112152, -5472);
    Engine.MoveTo(174088, -112152, -5240);
    Engine.MoveTo(174022, -112187, -5224);
    Engine.MoveTo(173349, -112366, -5174);
    Engine.MoveTo(173702, -113012, -4996);
    Engine.MoveTo(173263, -113337, -4768);
    Engine.MoveTo(172286, -113572, -4327);
    Engine.MoveTo(171765, -112941, -3960);
    Engine.MoveTo(171586, -112207, -3632);
    Engine.MoveTo(171568, -111702, -3579);
    Engine.MoveTo(171162, -111714, -3577);
    Engine.MoveTo(171194, -112249, -3488);
    Engine.MoveTo(171496, -113263, -3484);
    Engine.MoveTo(172005, -113733, -3539);
    Engine.MoveTo(173179, -113664, -3558);
    Engine.MoveTo(173639, -113208, -3629);
    Engine.MoveTo(173830, -112590, -3709);
    Engine.MoveTo(174329, -112983, -3593);
    Engine.MoveTo(175204, -113096, -3485);
    Engine.MoveTo(177476, -113069, -3485);
    Engine.MoveTo(177603, -112664, -3485);
    Engine.MoveTo(177943, -110995, -3665);
    Engine.MoveTo(178982, -110847, -3665);
    Engine.MoveTo(178457, -109280, -3665);
    Engine.MoveTo(178734, -108998, -3648);
    
 
 
 
 
 
  if user.inrange(178734, -108998, -3648, 100) then begin
Delay(500);
Engine.FaceControl(0, true);
   print('Arrived');
 
 
 
end;
end;
end;
end;
end;
begin 
Script.NewThread(@buff);
end.
 
Posted

So i should change to engine.dlgsel(2) to engine.bypasstoserver(2) ?

 

If so, i have a error: 

 

Incompatible types

you need use bypass string of button with engine.bypasstoserver('string');

Posted

Still cant do it. 

 

He just doesn't decide beetwen:

 

18951230_1488883421163899_31399594408410

 

 

The script its like that right now:

 

Engine.SetTarget('Tatiana');
  Engine.DlgOpen;
  delay(500);
  engine.dlgsel(4);
  delay(500);
    engine.dlgsel(2);
  delay(500);
  engine.bypasstoserver('Forge of the Gods, lower level - 1000 adena');
  delay(500);
  Engine.CancelTarget;
  delay(500);

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...