Results 1 to 5 of 5

Thread: Problems with rules in waypoints

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

    Problems with rules in waypoints

    Hello

    I've made a script and I'm having a problem with its waypoints. Making a resume, the waypoints are divided in:
    Open_Backpacks (bot closes everything and open all used backpacks) - okey with this
    Hunt (the character makes a turn in the whole respawn) - i think it's okey also

    Then, the bot would make a check here, and this is how i've made the action:
    if countitem("mana potion", "health potion) < 3 or cap < 20 then
    gotolabel("AFK")
    else
    gotolabel("HUNT")
    end

    If the pots or caps was too low, the char would go for a place where it would be afk until it logs out (i made a wait time higher than 15 minutes, cause im a rookie on ibot, and don't know how to make it disconnect), but for some reason, the ibot doesnt respect this rules, and go to the label AFK, that i've made just after the checking waypoint, then it goes to the place where it should be afk, and start the waypoints all over again, closing and opening backpacks and going to hunt... how should i solve it?

    Thanks.

  2. #2
    Normal User
    Join Date
    Jun 2012
    Location
    Sweden
    Posts
    1,671
    Mentioned
    18 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    8 Post(s)
    Reputation
    132
    Rep Power
    9
    PHP Code:
    if (itemcount("mana potion") < 3) or (itemcount("health potion") < 3) or (cap 20then
        gotolabel
    ("AFK")
    else
        
    wait(180000)
        
    gotolabel("HUNT")
    end 
    Last edited by soder; 11-19-2012 at 02:11 AM.

  3. #3
    Normal User
    Join Date
    Sep 2012
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5
    Oh! Thanks, gotta try this.

    Also, can I make, on this PHP code a wait time like wait(180000) on it, so it waits 3 minutes for the whole respawn? Or it should be divided in 2 different actions?

  4. #4
    Normal User
    Join Date
    Jun 2012
    Location
    Sweden
    Posts
    1,671
    Mentioned
    18 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    8 Post(s)
    Reputation
    132
    Rep Power
    9
    Updated my previous post

  5. #5
    Normal User
    Join Date
    Sep 2012
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5
    thanks! +rep

Posting Permissions

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