Skip to content

Problem With Script

Featured Replies

Yo, i use script for rebuff from the book, unfotunately bot doesnt work ok, sometimes dunno why he take buffs when he doesnt have mobs around him but most of the time he open book and still target mobs, result is his death bcs w/o buff...... check if any have some idea:

 

function checkAgro: boolean;
var npc: TL2Npc; 
begin
   result := not user.dead and ((not user.target.dead and user.target.attackable) or Engine.FindEnemy(npc, user, 1100));
end;
 
procedure leaveCombat;
begin
   engine.facecontrol(0,false); 
   while not user.dead and user.incombat and delay(200) do begin
      if checkAgro then begin
         if not engine.getfacestate(0) then engine.facecontrol(0,true);  
      end else if engine.getfacestate(0) then engine.facecontrol(0,false);  
   end;
end;
 
begin
    while delay(2000) do begin
        if checkBuff then begin
            while checkAgro do delay(20);
            leaveCombat;
            takeBuffs;
            Engine.FaceControl(0,true);
        end;
    end;
end.

Edited by mamike20009

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.