Ir para conteúdo
  • Cadastre-se

Alguns Scripts.


Posts Recomendados

Scripts

  • Logout 2% antes do level 9.

           Const
    
      Exp = 6350 // with 6400 EXP you are lvl 9 so change it as you like.
    
    
    while not terminated do
    
    begin
    
      UpdateWorld;
    
      if Self.Experience >= Exp then Self.Logout(True);
    
      Sleep(1000);
    
    end;  
  • Alerta com X de Cap.
Const 

  MinCap = 1 

  AlertFrom = 'C:/Windows/Media/Notify.wav' 


while not terminated do 

begin 

  UpdateWorld; 

  if self.capacity <= MinCap then 

  PlaySound(AlertFrom); 

  sleep(1000); 

end;  
Usar Obsidian Knife nos corpos de Minotaurs.
const  

 obsidian_knife = 5908;  

 skin_body = [4011, 4047, 4052, 4057];  


function searchIntArray(id:integer): boolean;  

var  

 i: integer;  

begin  

result := false;  

 for i := low(skin_body) to high(skin_body) do begin  

  if skin_body[i] = id then result := true;  

 end;  

end;  


function GetItemFromOpenBackpack(ID: integer): TItem;  

var  

  y: integer;  

begin  

  Result := nil;  

  for x := 0 to Self.Containers.Count - 1 do  

  begin  

    if x >= Self.Containers.Count then Break;  

    for y := 0 to Self.Containers.Container[x].Count - 1 do  

    begin  

      if y >= Self.Containers.Container[x].Count then Break;  

      if Self.Containers.Container[x].Item[y].ID = ID then  

      begin  

        Result := Self.Containers.Container[x].Item[y];  

        Exit;  

      end;  

    end;  

  end;  

end;  


function SkinBodies(id:integer): Boolean;  

var  

  x, y: integer;  

  knife: TItem;  

  t: integer;  

begin  

UpdateWorld;  

knife := GetItemFromOpenBackpack(obsidian_knife);  

if knife = nil then  

begin  

 Self.DisplayText('An Obsidian Knife could not be found, please open a container with it.');  

 exit;  

end;  

t := -1;  

 for x := -1 to 1 do begin  

  for y := -1 to 1 do begin  

  // if Screen.Tile[7+x, 5+y].Count >= 3 then begin  

  //  t := -2  

  // end else  t := -1;  

   if searchIntArray(Screen.Tile[7+x, 5+y].Item[Screen.Tile[7+x, 5+y].Count+t].ID) = true then begin  

    UpdateWorld;  

    knife := GetItemFromOpenBackpack(obsidian_knife);  

     if knife <> nil then begin  

      knife.UseWithGround(Self.X+X, Self.Y+Y, Self.Z);  

      Self.DisplayText('Attempted to skin a creature with the ID ' + IntToStr(Screen.Tile[7+x, 5+y].Item[Screen.Tile[7+x, 5+y].Count-1].ID) + '.');
Para usar nos de Dragons é só trocar os ID's.
Coloca spear na mão.
                                          const

WeaponID = 3271

SpearID = 3277

SpearOz = 20

SpearAmount = 1


Procedure PickUpSpears(Spears: TItem);

begin

if (Self.Capacity <= (Spears.Amount * SpearOz)) then

begin

if (Self.Capacity/SpearOz) > 1 then

Spears.MoveToContainer(Self.Containers.Container[0], 0, Int(Self.Capacity/SpearOz));

end else Spears.MoveToContainer(Self.Containers.Container[0], 0, 0);

Sleep(500);

end;


Function GetItemFromOpenBackpack(ID, Index: integer): TItem;

var

x: integer;

y: integer;

begin

Result := nil;

for x := 0 to Self.Containers.Count - 1 do

begin

if x >= Self.Containers.Count then Break;

if x = Index then Continue;

for y := 0 to Self.Containers.Container[x].Count - 1 do

begin

if y >= Self.Containers.Container[x].Count then Break;

if Self.Containers.Container[x].Item[y].ID = ID then

begin

Result := Self.Containers.Container[x].Item[y];

Exit;

end;

end;

end;

end;



function CountItemAmountFromOpenBackpack(ID: integer): integer;

var

x: integer;

y: integer;

begin

Result := 0;

for x := 0 to Self.Containers.Count - 1 do

begin

if x >= Self.Containers.Count then Break;

for y := 0 to Self.Containers.Container[x].Count - 1 do begin

if y >= Self.Containers.Container[x].Count then Break;

if Self.Containers.Container[x].Item[y].ID = ID then begin

Result := Result + Self.Containers.Container[x].Item[y].Amount;

end;

end;

end;

end;



while not terminated do

begin

UpdateWorld;

Weapon := GetItemFromOpenBackpack(WeaponID, Self.Containers.Count);

if Weapon <> nil then Weapon.MoveToBody(Self.Arrow, 0);

Spear := GetItemFromOpenBackpack(SpearID, 0);

if Spear <> nil then Spear.MoveToContainer(Self.Containers.Container[0], 0, 0);

if (Self.RightHand.ID = SpearID) then

begin

if (Self.RightHand.Amount < 90) then

begin

Spear := GetItemFromOpenBackpack(SpearID, Self.Containers.Count);

if Spear <> nil then Spear.MoveToBody(Self.RightHand, 0);

end;

end else begin

SpearCount := CountItemAmountFromOpenBackpack(SpearID);

if SpearCount >= SpearAmount then

begin

Self.RightHand.MoveToBody(Self.Arrow, 0);

Sleep(500);

Spear := GetItemFromOpenBackpack(SpearID, Self.Containers.Count);

if Spear <> nil then Spear.MoveToBody(Self.RightHand, 0);

end else if Self.RightHand.ID = 0 then Self.Arrow.MoveToBody(Self.RightHand, 0);

end;

Sleep(500);

end;  
Alerta quando faltam X spears.
const

  spear_amount = 5 //number of spears to alert at

  pause_time = 10 // number of seconds pause between alerts

  alert_file = 'c:\windows\media\notify.wav' // must be a wav file


begin 

  while not terminated do begin

    UpdateWorld;

    if Self.RightHand.Amount <= spear_amount then 

    begin

      PlaySound (alert_file);

      sleep(pause_time*1000);

    end;

    sleep(100);

  end;

end;  
Tira SS quando upa.
var 

  Level: integer; 


begin 

  UpdateWorld; 

  Level := Self.Level; 

  while not Terminated do 

  begin 

    UpdateWorld; 

    if Level <> Self.Level then 

    begin 

      Level := Self.Level; 

      ScreenShot('c:\level' + IntToStr(Level) + '.jpg'); 

    end; 

    Sleep(1000); 

  end; 

end;  
Sempre ficar na diagonal do monstro.
Const

Wanted='Bog Raider';// escolha aqui o mosntro.

AttackAt = 25

RampsID = [1950, 1952, 1954, 1956, 385, 1947, 434, 414, 604]


var

  x,Bla:Integer;

  Looting: boolean;



function IsCreatureBesideYou(c: TCreature): boolean;

begin

   UpdateWorld;

   if (abs(c.X-self.X) <= 1) and (abs(c.Y-self.Y) <= 1) then begin

    if c.Z = self.Z then

     begin

     Result := True;

     Exit;

    end;

   end;

   Result := False;

end;



function GetTileFromXYZ(X, Y, Z: integer): TTile;

begin

  Result := nil;

  if abs((Self.X - 7) - X) > 14 then Exit;

  if abs((Self.Y - 5) - Y) > 11 then Exit;

  if Self.Z <> Z then Exit;

  Result := Screen.Tile[abs((Self.X - 7) - X), abs((Self.Y - 5) - Y)];

end;

function IsTileWalkable(Tile: TTile): boolean;

begin

  Result := True;

  for Z := 0 to Tile.Count - 1 do

  begin

    if Tile.Item[Z].Properties.Hole then

    begin

      Result := False;

    end

    else if Tile.Item[Z].Properties.Stairs then

    begin

      Result := False;

    end

    else if not Tile.Item[Z].Properties.Walkable then

    begin

      OutputDebugString('Not Walk: ' + IntToStr(Tile.Item[Z].ID));

      Result := False;

    end;

    else

    begin

      for x := low(RampsID) to high(RampsID) do

      begin

       if Tile.Item[Z].ID = RampsID[x] then Result := False;

      end;

    end;

  end;

end;


function GetCreatureBesideYou: TCreature;

begin

   UpdateWorld;

   Result := Nil;

   for x := 0 to Creatures.Count - 1 do

   begin

      UpdateWorld;

      if (Creatures.Creature[x].Name=Wanted) then

      if IsCreatureBesideYou(Creatures.Creature[x]) then

      begin

       if Creatures.Creature[x].ID <> Self.ID then

        begin

         UpdateWorld;

         Result := Creatures.Creature[x];

         Exit;

        end;

      end;

   end;

end;


var

Moved:boolean;


begin

updateworld;

G:=false;

T:=false;

while not terminated do

     begin

     Bla:=Self.Containers.Count;

     updateworld;

     Creature:=GetCreatureBesideYou;

     if Creature<>nil then

     if Creatures.Creature[x].Health>AttackAt then

        begin

            if (Self.X<>Creature.X) and (Self.Y=Creature.Y) then

            begin

            Tile:=GetTileFromXYZ(Self.x,Self.y-1,self.z);

            if Tile<>nil then

            if IsTileWalkable(Tile) then

               begin

               Self.MoveUp;

               Moved:=true;

               end;

            If (Moved=False) then

               begin

               Tile:=GetTileFromXYZ(Self.x,Self.y+1,self.z);

               if Tile<>nil then

               if IsTileWalkable(Tile) then

               Self.MoveDown;

               end;

            end;

            Moved:=false;

            if (Self.X=Creature.X) and (Self.Y<>Creature.Y) then

            begin

            Tile:=GetTileFromXYZ(Self.x-1,Self.y,self.z);

            if Tile<>nil then

            if IsTileWalkable(Tile) then

               begin

               Self.MoveLeft;

               Moved:=true;

               end;

            If (Moved=False) then

               begin

               Tile:=GetTileFromXYZ(Self.x+1,Self.y,self.z);

               if Tile<>nil then

               if IsTileWalkable(Tile) then

               Self.MoveRight;

               end;

            end;

            end;

        sleep(1000);

     end;

end;  
Logout em X minutos.
Const  

  Minutes = 70   


begin  

  Sleep(Minutes*60000);  

  Self.Logout(True);  

end;  
Alerta quando a Soft Boots acabar.
Const 

  Soft_Boots_In_Use_ID = ???? //Check the ID of the soft boots when they are on the boots. 

  Sound_Path = 'C:/Windows/Media/Notify.wav' // you may change only to wav files. 


while not terminated do 

begin 

  UpdateWorld; 

  if Self.Feet.ID <> Soft_Boots_In_Use_ID then 

  PlaySound(Sound_Path); 

  sleep(500); 

end;  
Script de healar.
const

minMana = 20; //minimum mana

minHealth = 600; //Life pra tomar o Pote

maxHealth = 780; //Life pra usar Exura abaixo disso

potionid = 266; //id da potion

spellnome = 'exura' //nome da magia


while not Terminated do

begin

UpdateWorld;

if (Self.Health < minHealth) then

begin

Self.Containers.UseItemWithSelf(potionid);

Sleep(1000);

end;

else

begin

if (Self.Health < maxHealth) and (Self.Mana > minMana ) then

begin

Self.Say(spellnome);

Sleep(1500);

end;

end;

Sleep(100);

end;  
Usar mana potion com X de mana.
const

minMana = 200; //Mana pra usar Mf pequena


while not Terminated do

begin

UpdateWorld;

if (Self.Mana < minMana) then

begin

Self.Containers.UseItemWithSelf(268)

Sleep(1000);

end;

Sleep(100);

end;  
Treino com Slimes.
function Attacking: boolean;

begin

UpdateWorld;

for x := 0 to Creatures.Count - 1 do

begin

UpdateWorld;

if Creatures.Creature[x].Attacking then

begin

Result := True;

Exit;

end;

end;

Result := False;

Exit;

end;


function GetFollowedCreatureID: integer;

begin

UpdateWorld;

for x := 0 to Creatures.Count - 1 do

begin

UpdateWorld;

if Creatures.Creature[x].Following then

begin

Result := Creatures.Creature[x].ID;

Exit;

end;

end;

end;


var

MotherSlime, X1, Y1: integer;

begin

MotherSlime := GetFollowedCreatureID;

while not Terminated do

begin

UpdateWorld;

if not Attacking then

begin

UpdateWorld;

for x := 0 to Creatures.Count - 1 do

begin

UpdateWorld;

if Creatures.Creature[x].ID <> MotherSlime then

begin

if (Creatures.Creature[x].Name <> Self.Name) and Creatures.Creature[x].NPC then

begin

UpdateWorld;

X1 := Creatures.Creature[x].X;

Y1 := Creatures.Creature[x].Y;

if (X1 - Self.X = 1) or (X1 - Self.X = 0) or (X1 - Self.X = -1) then

begin

UpdateWorld;

if (Y1 - Self.Y = 1) or (Y1 - Self.Y = 0) or (Y1 - Self.Y = -1) then

begin

Creatures.Creature[x].Attacking := true;

Break;

end;

end;

end;

end;

end;

end;

Sleep(1000);

end;

end; 
Reconect e abre a BP.
const

Account = 1234567; // Sua conta

Password = 'xxxxxxxx'; // Sua senha

Character = 'xxxxxxxx'; // Nome do Char

World = 'Antica'; // Mundo Que vc Joga

ServerIP = ''; // Deixa em branco


procedure Login

var x: integer;

begin

repeat

Self.Login(Account, Password, Character, World, ServerIP);

Sleep(7000);

for x := 0 to 200 do

begin

if Self.Connected then Break;

Sleep(100);

end;

until Self.Connected;

end;


var x: integer;


while not Terminated do

begin

UpdateWorld;

if not Self.Connected then

begin

Login;

Sleep(2000);

UpdateWorld;

Self.Backpack.Open;

Sleep(2000)

UpdateWorld;

for x := 0 to Self.Containers.Container[0].Count do

begin

if x >= Self.Containers.Container[0].Count then Break;

if Self.Containers.Container[0].Item[x].Properties.Container then

begin

Self.Containers.Container[0].Item[x].OpenInNewWindow;

Sleep(2000);

end;

end;

end;

Sleep(1000);

end;  
Jogar o loot em X sqm's.
Const 

  ItemsIDs = [2885,3147,2920] 

  X = 32352 

  Y = 32228 

  Z = 6 


function GetItemFromOpenBackpack(ID: integer): TItem; 

var 

  x: integer; 

  y: integer; 

begin 

  Result := nil; 

  for x := 0 to Self.Containers.Count - 1 do 

  begin 

    if x >= Self.Containers.Count then Break; 

    for y := 0 to Self.Containers.Container[x].Count - 1 do 

    begin 

      if y >= Self.Containers.Container[x].Count then Break; 

      if Self.Containers.Container[x].Item[y].ID = ID then 

      begin 

        Result := Self.Containers.Container[x].Item[y]; 

        Exit; 

      end; 

    end; 

  end; 

end; 


while not terminated do 

begin 

  UpdateWorld; 

  for i := self.containers.count - 1 downto 0 do 

  begin 

    for x1 := self.containers.container[i].count - 1 downto 0 do 

    begin 

      ok := false;     

      for y1 := Low(ItemsIDs) to High(ItemsIDs) do 

      begin 

        if self.containers.container[i].item[x1].id = ItemsIDs[y1] then 

          ok := true; 

      end; 

      if ok then 

      begin 

        self.containers.container[i].item[x1].movetoground(X,Y,Z,0); 

        Self.DisplayText(self.containers.container[i].item[x1].id); 

        sleep(500); 

      end;  

    end; 

  end; 

  sleep(100); 

  Items := 0; 

  for i := low(ItemsIDs) to High(ItemsIDS) do 

  begin 

    Item := GetItemFromOpenBackpack(ItemsIDs[i]); 

    if Item <> nil then 

    Items := Items + 1; 

  end; 

  if not Items then 

    break; 

  sleep(100); 

end;  
Andar com W A S D.

Const

DiagnoalWalking = 1 // 1-enable diagnoal, 0-disable.


procedure Event_KeyDown(Key:integer);

begin

Updateworld;

case Key of

87:Self.MoveUp; //W

65:Self.MoveLeft; //A

83:self.MoveDown; //S

68:Self.MoveRight; //D

end;

if DiagnoalWalking then

Case Key of

81:Self.MoveUpLeft; //Q

69:Self.MoveUpRight; //E

90:Self.MoveDownLeft; //Z

67:Self.MoveDownRight; //C

end;

end;


while not terminated do

begin

ProcessEvents;

Sleep(100);

end;

É isso galera, peguei eles no forum do NG.

Vou adicionar mais assim que achar.

Espero que gostem.

Equipe TibiaKing.com ~


 

w97eR.png

Legalize it.

Link para o post
Compartilhar em outros sites

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo