Results 1 to 6 of 6

Thread: Help with an Action on Cavebot

  1. #1
    Normal User
    Join Date
    Jul 2012
    Posts
    57
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5

    Question Help with an Action on Cavebot

    Hello guys i have this action

    --Rft
    local mplocal = itemcount('strong mana potion')
    local mana = positive(MPtobuy - mplocal) * MPprice
    local health = 0
    local food = positive(50 - itemcount('brown mushroom')) * 10
    local total = mana + health + food

    if islocation() then
    closewindows()
    wait(1000)
    openitem(Mainbp,'back')
    wait(1500)
    resizewindows()
    wait(600)
    depositall()
    wait(1000)
    npcsay('withdraw '..total)
    wait(1000)
    npcsay('yes')
    wait(1000)
    end


    the bot isnt counting the strong mana potions... always he withdraw 14100... can anyone tell me why?

  2. #2
    Normal User
    Join Date
    Jun 2012
    Posts
    31
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    11
    Rep Power
    5
    You need to have, in the Setup part of the Actions section, this:

    MPtobuy = 50 -- amount you want to buy
    MPprice = 50 -- price per pot

  3. #3
    Normal User
    Join Date
    Jul 2012
    Posts
    57
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5
    But i have... the question is ... the bot doesn't count the strong mana potions and the mushroons... and the bp is openned .-. he withdraw as i had 0 strong and 0 mushrooms. That's the problem >_<

    Thanks for the support

  4. #4
    Normal User
    Join Date
    May 2012
    Posts
    105
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    11
    Rep Power
    5
    i have same problem with count parcels .... but u have strong and mushroms in other bp than main ?
    i think its bug ... and bot count just MAIN bp ... ;/

  5. #5
    Normal User blablabla's Avatar
    Join Date
    Jun 2012
    Location
    Curitiba, Brazil
    Posts
    242
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    22
    Rep Power
    5
    Manas and food must be visible. I use this one and it works fine. I edited it for your needs.

    PHP Code:
    if islocation() then

       closewindows
    ()
       
    wait(10001500)
       
    openitem(Mainbp'back')
       
    wait(10002000)
       
    resizewindows()
       
    wait(5001000)
       
    say('hi'wait(10002000)
       
    npcsay('deposit all'wait(500800)
       
    npcsay('yes'wait(500800)

    local mana positive(MPtobuy itemcount('strong mana potion')) * MPprice
    local health 
    positive(Foodtobuy itemcount('brown mushroom')) * 10
    local Total 
    mana health

          
    if Total 0 then
             npcsay
    ('withdraw '..Totalwait(500800)
             
    npcsay('yes'wait(500800)
          
    end
    end 
    Last edited by blablabla; 08-16-2012 at 05:05 PM.

  6. #6
    Normal User
    Join Date
    Jul 2012
    Posts
    57
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5
    Thank you bro, im going to test it later ^^

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •