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


lightfree

Rekomendowane odpowiedzi

Opublikowano

Pomoze mi kots rozkminic czemmu mi potow nie kupuje ani gp z banku nie bierze mam lebele dobrze ustawione.

 

 

--------------
--------------
----Scrypt--
------By:-
------Petos---
----------------    

--------- BP SETUP ----------
-- [BP 1] - głowny bp
-- [BP 2] - bp na itemki
-- [BP 3] - gold (bp mozesz sobie dowolnie ustawic w lootingu)

--------- DP SETUP ----------
-- [DP 1] - bp na lota

------ REFILL SETTINGS ------
local MinMana = 60 --- Od ilu heal potów ma wracać z Hunta.
local MaxMana = 550  --- Z iloma potami ma zaczynac hunt.
------- HUNT SETTINGS --------
local GoldBP = 8860 --- id bp do którego ma chować gp (mozesz ustawic poprostu w lootingu numer bp ;p)
local MinCap = 60-- ilość capa od której ma wracać do dp.
------- EXTRA SETTINGS -------
local HideEquipment = true --- czy bot ma minimalizować eq.
local LogoutStamina = true --- czy bot ma pójść do dp i sie wylogować jak bedzie miał 16 staminy.

--------------------------------------------------------------------
--------------------------------------------------------------------
--------------------------------------------------------------------
--------------------------------------------------------------------
--------------------------------------------------------------------

Targeting.Start()
Looter.Start()

registerEventListener(WALKER_SELECTLABEL, "onWalkerSelectLabel")

    print([[
    Scrypt
By:
Wojtek]])
    wait(5000)

function onWalkerSelectLabel(labelName)
    if (labelName == "Checker") then
        Walker.ConditionalGoto((Self.Cap() < MinCap) or (Self.ItemCount(268) <= MinMana) or ((LogoutStamina) and (Self.Stamina() < 840)), "Leave", "Hunt")

    elseif (labelName == "Potions") then
        Walker.Stop()
        if (Self.ItemCount(268) < MaxMana) then
            Self.SayToNpc({"hi", "flasks", "yes", "yes", "yes", "yes", "yes", "yes", "trade"}, 65)
            wait(2000)
            if (Self.ItemCount(268) < MaxMana) then
                BuyItems(268, MaxMana)
                wait(500)
            end
            wait(200, 500)
        end
        Walker.Start()

    elseif (labelName == "CheckStuff") then
        Walker.ConditionalGoto((Self.ItemCount(268) < MaxMana), "Bank", "ToHunt")

    elseif (labelName == "Bank") then
        local withdrawManas = math.max(MaxManas - Self.ItemCount(268), 0)*50
        local totalmoneyneeded = (withdrawManas - Self.ItemCount(268)*5)
        local MATHCEIL = (totalmoneyneeded)
        Walker.Stop()
        Self.SayToNpc({"hi", "deposit all", "yes"}, 65)
        if (totalmoneyneeded > 0) then
            Self.SayToNpc({"withdraw " .. MATHCEIL, "yes", "balance"}, 65)   
        end  
        wait(2000)
        Walker.Start()
        
    elseif (labelName == "Deposit") then
        Walker.Stop()
        Self.ReachDepot()
        Self.DepositItems({237, 1}, {236, 1}, {3079, 1}, {7456, 1}, {8073, 1}, {10244, 1}, {3324, 1}, {3369, 1}, {3371, 1}, {3415, 1}, {3028, 1}, {3032, 1}, {3048, 1}, {11475, 1}, {3029, 1}, {3030, 1}, {10277, 1}, {3033, 1}, {10320, 1}, {3574, 1}, {5925, 1}, {237, 1}, {239, 1}, {2995, 1}, {3355, 1}, {3277, 1}, {3552, 1}, {3577, 1})
        wait(1000)
        Self.WithdrawItems(1, {268, 0,(MaxMana-Self.ItemCount(268))})
        if (LogoutStamina) and (Self.Stamina() < 960) then
            Walker.Stop()
        else
            Walker.Start()
        end

    elseif (labelName == "ResetBP") then
        Walker.Stop()
        Container.Close(GoldBP)
        wait(1000)        
        Container.GetFirst():OpenChildren(GoldBP)
        wait(1000)
        Container.GetByName(GoldBP):Minimize()
        if (HideEquipment) then
            Client.HideEquipment()
            wait(1000)
        end
        Walker.Start()    
    end
end

----------------------- Functions ----------------------
function BuyItems(item, count) -- item = item id, count = how many you want to buy up to
    wait(900, 1200)
    if (Self.ItemCount(item) < count) then
        Self.ShopBuyItem(item, (count-Self.ItemCount(item)))
        wait(200, 500)
    end
end

Self.ReachDepot = function (tries)
    local tries = tries or 3
    Walker.Stop()
    local DepotIDs = {3497, 3498, 3499, 3500}
    local DepotPos = {}
    for i = 1, #DepotIDs do
        local dps = Map.GetUseItems(DepotIDs)
        for j = 1, #dps do
            table.insert(DepotPos, dps[j])
        end
    end
    local function gotoDepot()
        local pos = Self.Position()
        print("Depots found: " .. tostring(#DepotPos))
        for i = 1, #DepotPos do
            location = DepotPos
            Self.UseItemFromGround(location.x, location.y, location.z)
            wait(1000, 2000)
            if Self.DistanceFromPosition(pos.x, pos.y, pos.z) >= 1 then
                wait(5000, 6000)
                if Self.DistanceFromPosition(location.x, location.y, location.z) == 1 then
                    Walker.Start()
                    return true
                end
            else
                print("Something is blocking the path. Trying next depot.")
            end
        end
        return false
    end
    
    repeat
        reachedDP = gotoDepot()
        if reachedDP then
            return true
        end
        tries = tries - 1
        sleep(100)
        print("Attempt to reach depot was unsuccessfull. " .. tries .. " tries left.")
    until tries <= 0

    return false
end

Map.GetUseItems = function (id)
    if type(id) == "string" then
        id = Item.GetID(id)
    end
    local pos = Self.Position()
    local store = {}
    for x = -7, 7 do
        for y = -5, 5 do
            if Map.GetTopUseItem(pos.x + x, pos.y + y, pos.z).id == id then
                itemPos = {x = pos.x + x, y = pos.y + y, z = pos.z}
                table.insert(store, itemPos)
            end
        end
    end
    return store
end

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...