Results 1 to 7 of 7

Thread: Ajuda, Action de treino.

  1. #1
    iBot User
    Join Date
    Feb 2013
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    4 Post(s)
    Reputation
    10
    Rep Power
    4

    Ajuda, Action de treino.

    Galera, tentei criar uma action em que o bot ataque o target até ele chegar em 20% de hp e que só volte a atacar com 30% porém sem sucesso.

    Alguém pode dar uma força?

    PHP Code:
    if (targethpperc 20then
        settargeting
    ("off")
        
    wait(1000)
        
    stopattack()
    elseif
        (
    targethpperc 30then
        settargeting
    ("on")
        
    wait(1000)
    end 

  2. #2
    Focus Group Targets's Avatar
    Join Date
    Nov 2013
    Location
    PoA - Brazil
    Posts
    456
    Mentioned
    18 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    48 Post(s)
    Reputation
    109
    Rep Power
    5
    Lua Code:
    if(target.hpperc < 20) then
        settargeting('no')
        wait(1000)
        stopattack()
    else
       if(target.hpperc >= 30) then
              settargeting('on')
              wait(1000)
       end
    end



  3. #3
    iBot User
    Join Date
    Feb 2013
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    4 Post(s)
    Reputation
    10
    Rep Power
    4
    Quote Originally Posted by TargetScripts View Post
    Lua Code:
    if(target.hpperc < 20) then
        settargeting('no')
        wait(1000)
        stopattack()
    else
       if(target.hpperc >= 30) then
              settargeting('on')
              wait(1000)
       end
    end
    Não funcionou =/

  4. #4
    iBot User gothiactc's Avatar
    Join Date
    Nov 2013
    Location
    Brazil
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    10
    Rep Power
    4
    the problem is on settargeting('on'), settargeting('no'), I don't know iBot methods but the parameter i think is 'no' and 'yes', if the hppercent is lowen than 20 you must set it to 'no' to disable elseif is higer than 30 percent you must set it to yes to enable targeting.

    Try this one:

    Code:
    if(target.hpperc < 20) then
        settargeting('no')
        wait(1000)
        stopattack()
    else
       if(target.hpperc >= 30) then
              settargeting('yes')
              wait(1000)
       end
    end
    Last edited by gothiactc; 03-12-2014 at 03:19 PM.

  5. #5
    iBot User
    Join Date
    Feb 2013
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    4 Post(s)
    Reputation
    10
    Rep Power
    4
    Quote Originally Posted by gothiactc View Post
    the problem is on settargeting('on'), settargeting('no'), I don't know iBot methods but the parameter i think is 'no' and 'yes', if the hppercent is lowen than 20 you must set it to 'no' to disable elseif is higer than 30 percent you must set it to yes to enable targeting.

    Try this one:

    Code:
    if(target.hpperc < 20) then
        settargeting('no')
        wait(1000)
        stopattack()
    else
       if(target.hpperc >= 30) then
              settargeting('yes')
              wait(1000)
       end
    end
    Don't work too

  6. #6
    iBot User gothiactc's Avatar
    Join Date
    Nov 2013
    Location
    Brazil
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    10
    Rep Power
    4
    Quote Originally Posted by Paramax410 View Post
    Don't work too
    http://www.tibiaibot.com/forum/showt...=slime+trainer

    try this one, I hope that works. Or try to change where settargetting('no') to ('on') and settargetting('yes') to ('off').
    Code:
    if(target.hpperc < 20) then
        settargeting('off')
        wait(1000)
        stopattack()
    else
       if(target.hpperc >= 30) then
              settargeting('on')
              wait(1000)
       end
    end
    Last edited by gothiactc; 03-13-2014 at 01:57 AM.

  7. #7
    Focus Group mexicowss's Avatar
    Join Date
    May 2012
    Location
    Brasil
    Posts
    440
    Mentioned
    20 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    59 Post(s)
    Reputation
    128
    Rep Power
    6
    uso essa para treinar meus chars desde sempre:
    PHP Code:
    local treinador 'Juju Canibal'
    if target.name == treinador and target.hppc <= 50 then
        stopattack
    ()
    elseif 
    getcreature(treinador).hpperc >= 50 and target.name ~= treinador then
        attack
    (treinador)
    end 
    click the image below to see my thread.



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
  •