Everyone who has never used our Bots before, can test each one for 2 days without any limitation.
The trial is given automatically when you login on the Bot, but in some cases it wouldn't work (security reasons).
If this happens, send me a private message and i will be checking the failed trials manually and adding it for those who didn't get it.
We are looking for resellers who may accept payment methods different from ours, including classictibia's cash, realesta's cash, mastercores' cash, etc. Interested? Click here at anytime.



Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
cavebot + rune maker
#1
hello i need help, im are botting on nosthalther one druid lvl 20 on rotworms, but i need make uhs too. the problem is i use weapon two handed. and when my druid get X mana, try to put in the "empty hand" and is not possible beacuse the weapon is two handed. they try all time put in this hand and tell the spell but is not possbile. thank you
Reply

#2
Hello.

The Bot has no way of knowing it's a two handed weapon, because the game-client doesn't provides such information, it's server-side. I could specify the ids of every two handed item, but that wouldn't be a 100% solution, because there are custom items on the many servers that Kasteria OTBot works on. So I'm going to add a checkbox option in Runemaker for that.

For now, you can use this script. It's something I haven't tested, but I believe it will work.
local CONFIG = {
    MANA_CONDITION = 'Mana above', -- Condition to mane runes: Mana above or Mana percent
    MANA_RANGE = { Min = 300, Max = 400 }, -- Mana to make rune. Sorts a random value between this range to make rune.
    RUNE_SPELL = 'adura vita',
    HAND = 'lhand', -- use lhand for left hand and rhand for right hand.
    WEAPON_BP = 'red backpack', -- If there is any item on specified hand then move to this container while making runes but move back to hand.
}
  
  
local ACTION_MAX_ATTEMPTS = 5
local BLANK_RUNE_ID = 3147

local currentValue = -1
if CONFIG.MANA_CONDITION:lower() == 'mana above' then
    currentValue = mp()
else
    currentValue = mppc()
end

if RUNE_MANA == nil then
    RUNE_MANA = random(CONFIG.MANA_RANGE.Min, CONFIG.MANA_RANGE.Max)
end

if gethanditem == nil then
    function gethanditem(hand)
        if hand:lower() == 'lhand' then
            return lhand()
        else
            return rhand()
        end
    end
end
  
if findblankrune == nil then
    function findblankrune()
        local containers = getcontainers()
        for _, cont in ipairs(containers) do
            for __, item in ipairs(cont.items) do
                if item.id == BLANK_RUNE_ID then
                    return cont.index
                end
            end
        end
        return -1
    end
end

if currentValue >= RUNE_MANA and cancast() then
    local blankRuneLocation = findblankrune()
    if blankRuneLocation == -1 then
        printerror('Could not find a blank rune.')
        playsound('default')
        flashclient()
    else
        local itemHand = gethanditem(CONFIG.HAND)
        MOVED_WEAPON_ID = 0
        for i = 1, ACTION_MAX_ATTEMPTS do
            if itemHand.id ~= 0 and itemHand.id ~= BLANK_RUNE_ID then
                moveitems(itemHand.id, CONFIG.WEAPON_BP, CONFIG.HAND)
                wait(500, 800)
                MOVED_WEAPON_ID = itemHand.id
                itemHand = gethanditem(CONFIG.HAND)
            else
                break
            end
        end

        for i = 1, ACTION_MAX_ATTEMPTS do
            if itemHand.id == 0 and blankRuneLocation >= 0 then
                if moveitems(BLANK_RUNE_ID, CONFIG.HAND, blankRuneLocation, 1) then
                    wait(500, 800)
                    itemHand = gethanditem(CONFIG.HAND)
                else
                    blankRuneLocation = findblankrune()
                end
            else
                break
            end
        end

        if itemHand.id == BLANK_RUNE_ID then
            while cancast() == false do
                wait(100)
            end

            cast(CONFIG.RUNE_SPELL)
            wait(500, 800)
            itemHand = gethanditem(CONFIG.HAND)

            for i = 1, ACTION_MAX_ATTEMPTS do
                if itemHand.id ~= 0 then
                    moveitems(itemHand.id, blankRuneLocation, CONFIG.HAND, 1)
                    wait(500, 800)
                    itemHand = gethanditem(CONFIG.HAND)
                else
                    break
                end
            end
        end

        if MOVED_WEAPON_ID > 0 then
            for i = 1, ACTION_MAX_ATTEMPTS do
                if itemHand.id == 0 then
                    moveitems(MOVED_WEAPON_ID, CONFIG.HAND, CONFIG.WEAPON_BP)
                    wait(500, 800)
                    itemHand = gethanditem(CONFIG.HAND)
                else
                    break
                end
            end
        end
    end
end
Reply

#3
|Only Registered members can see download links. | Click here to buy subscription or here to register.

sorry but this script dont work, get this error
10:53:36 - LUA Script -> Persistent03: NLua.Exceptions.LuaScriptException: attempt to index a nil value
Reply

#4
|Only Registered members can see download links. | Click here to buy subscription or here to register.

Hello.

I've updated the script. Please, try again!
Reply

#5
Hello, im trying this but get the same message
Reply



Forum Jump:



Forum software by © MyBB Theme © iAndrew 2016