Ir para conteúdo
Faça parte da equipe! (2024) ×
Conheça nossa Beta Zone! Novas áreas a caminho! ×
  • Quem está por aqui   0 membros estão online

    • Nenhum usuário registrado visualizando esta página.

Script para pegar spears!


geibson
 Compartilhar

Posts Recomendados

TIBIABOT NG!

 

Gente na função Pick up spears o bot pega spears q tah no chão e coloca na mão!

eu qria um script q ele pegasse a spear do monstro e colocasse diretamente na mão!

pq as vz eu fiko atacando com a mão... e minha bp tah cheia de spears!!

AGRADEÇO DESDE JÁH!

VLW abraço! :rolleyes:

Link para o comentário
Compartilhar em outros sites

  • 2 semanas atrás...

Serve isso aki?

 

const

WeaponID = 3268 // 3282 = Morning Star

SpearID = 3277 // 3277 = Spear, 1781 = Small Stone

SpearOz = 20 // Spear = 20, Small Stone = 3

SpearAmount = 1 // How many must have before switching back to spear

 

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;

Link para o comentário
Compartilhar em outros sites

Este tópico está impedido de receber novos posts.
 Compartilhar

×
×
  • Criar Novo...

Informação Importante

Nós fazemos uso de cookies no seu dispositivo para ajudar a tornar este site melhor. Você pode ajustar suas configurações de cookies , caso contrário, vamos supor que você está bem para continuar.