Results 1 to 5 of 5

Thread: Help with Action line for refilling

  1. #1
    Normal User
    Join Date
    Dec 2012
    Location
    Sweden
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    4

    Help with Action line for refilling

    Hello i need some help with a action line, the script works fine except that it doesn't go back to refill when it have below the amount of mana potions to stop hunt.

    First of all this is my setup

    PHP Code:
    mainBp "Backpack of holding"
    lootBp "Orange backpack"
    supplyBp "Jewelled backpack"
    goldBp "Blue backpack"


    stashBp "Backpack" -- BP som andrar bp ska ligga i DP
    nonstackableBp 
    "Brocade backpack"
    stackableBp "purple backpack"
                        
                           
    nameMp "Strong Mana potion" -- Mana potion to use
    maxMp 260 -- Number of Mana potions to buy
    minMp 
    40 -- Number of Mana potions to stop hunting
    priceMp 
    80 -- Mana potions price

    nameSpear 
    "Royal spear" -- Spear to use
    maxSpear -- Number of Spears to buy
    minSpear 
    -- Number of Spears to stop hunting
    priceSpear 
    25 -- Spear price

    nameHp 
    "Great Spirit Potion" -- Health/Spirit potion to use
    maxHp -- Number of Health/Spirit potions to buy
    minHp 
    -- Number of Health/Spirit potions to stop hunting
    priceHp 
    190 -- Health/Spirit potions price

     
    dropVials 
    30 -- Minimum number of vials to drop if you're cap is less than minCap+50 (Turn off the VialDropper action to disable)
    minCap = 100 -- Minimum Capacity to have to stop hunting
    extraGp = 1000 -- Extra gold to withdraw when resupplying (For travel, ect)


    useSoftboots = true -- Will use and refill softboots if true (True or False)
    otherBoots = "boots of haste" -- What to wear instead of Soft Boots (Only matters if useSoftboots is true)
    minMana = 90 -- Minimum mana to equip Soft Boots(Only matters if useSoftboots is true)

    pvpServer = true -- Is this a PvP server? (true or false) 
    And this is the line that's failing

    PHP Code:
    if (itemcount(nameSpear) < minSpear or (itemcount(nameMp) < minMp or itemcount(nameHp) < minHp or cap minCapthen gotolabel("leaveblue"end 
    as i said it works fine when you have below the amount of spear that you wanna go refill to, only the part with manas is not working.

    anyone has a suggestion to what i could replace that line with so it works??

  2. #2
    Normal User RafiXWPT's Avatar
    Join Date
    Jun 2012
    Location
    (Poland) http://rafixwptscripts.com
    Posts
    1,602
    Mentioned
    31 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    128 Post(s)
    Reputation
    128
    Rep Power
    9
    because
    PHP Code:
    itemcount(nameSpear
    is bad way to do that, replace it with
    PHP Code:
    weaponamount 
    , also "(" ar wrong, the good action is:
    PHP Code:
    if weaponamount minSpear
    or itemcount(nameMp) < minMp
    or itemcount(nameHp) < minHp
    or cap minCap
     then gotolabel
    ("leaveblue")
    end 


    but I think there should be also line with "gotolabel("resp")" or something like that:

    PHP Code:
    if weaponamount minSpear
    or itemcount(nameMp) < minMp
    or itemcount(nameHp) < minHp
    or cap minCap
     then gotolabel
    ("leaveblue")
     else 
    gtolabel("resp")
    end 

  3. #3
    Normal User
    Join Date
    Dec 2012
    Location
    Sweden
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    4
    Thanks for the help, Appreciate it

    will try it out later, hope it works xD

  4. #4
    Normal User RafiXWPT's Avatar
    Join Date
    Jun 2012
    Location
    (Poland) http://rafixwptscripts.com
    Posts
    1,602
    Mentioned
    31 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    128 Post(s)
    Reputation
    128
    Rep Power
    9
    u must replace "resp" with your label name, idk what u have there, action should works

  5. #5
    Normal User
    Join Date
    Dec 2012
    Location
    Sweden
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    4
    Yea i got that part, i actually used a diffrent action wtp for that after the refill wtp.

    but i see that your way of doing it is much better

    Thanks again for taking your time to help me

Posting Permissions

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