Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

Pomoc w scrypcie


alkvito

Rekomendowane odpowiedzi

Opublikowano

Elos

Pomóżcie mi przekształcić skrypta żeby przerzucał kamienie do łapy (ja go znalazłem ale przerzuca on kamienie tam gdzie są strzały, albo do drugiego bp)

 

 

Oto skrypt

const

WeaponID = 3271

SpearID = 1781

SpearOz = 3.60

SpearAmount = 20

Fluid = [99, 2886, 2887, 2887, 2888, 2889, 2890, 2891]

 

 

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;

 

Procedure FindSpears;

var

x, y, z, i, f: integer;

Tile: TTile;

begin

for x := -1 to 1 do

begin

for y := -1 to 1 do

begin

Tile := Screen.Tile[x + 7, y + 5];

begin

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

begin

if i >= Tile.Count then Break;

if Tile.Item.ID = SpearID then

begin

if i = 1 then PickUpSpears(Tile.Item);

else for f := Low(Fluid) to High(Fluid) do if Tile.Item[i-1].ID = Fluid[f] then PickUpSpears(Tile.Item);

else Tile.Item[i-1].MoveToGround(Self.X+Random(-2,3), Self.Y+Random(-2,3), Self.Z, 0);

end;

end;

end;

end;

end;

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;

FindSpears;

 

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;

 

Z góry THX

Sho%20Yer.png
Opublikowano

Cavebot ma funkcję refill ammo... testowałem na najnowszej wersji i działa, tylko ważne, żeby oprócz kamieni w bp, na początku kamienie były w miejscu na strzały. Bot przerzuca to w taki sposób:

 

BP => Miejsce na strzały=> Wolna ręka

 

 

EXPmIpC.gif

Opublikowano

Sprawdzilem to i bot niechce mi przezucic do pustej reki

Czemu??

 

Kurde nieche mi przerzucać kamieni tam gdzie są strzały to przeżuca ael już tam gdzie ręka to nie. amozę to ma coś wspólnego z wersja bo ja crackowałem tak jak wrotek pisał i jak urachamiam to mi pisze tak

http://www.wrzuta.pl/obraz/y5Ygb39msW/bot

 

powinno tak pisać? Czy powinno pisać 4.7.7

Sho%20Yer.png
Opublikowano

hmm... ja wiem dlaczego tak jest chyba, ja mam oryginalnie kupionego bota, a ty scrackowanego i to jest pewnie powód...

EXPmIpC.gif

  • 2 lata później...
Gość
Ten temat został zamknięty. Brak możliwości dodania odpowiedzi.
×
×
  • Dodaj nową pozycję...