Jump to content

lediv

Members
  • Posts

    50
  • Joined

  • Last visited

Posts posted by lediv

  1. When our character has some debuffs like the one shown on the screen it would not heal, neither with spell nor with senzu bean.

     

    This is a real serious issue since a lot of monsters throw poison at us etc, and the bot dies, could you please fix?

    thanks

    healing.png

  2. On 4/10/2021 at 1:11 AM, strzala said:

    Hmmm don't  work for me i correct setup id 😞

    remember to put correct id of the item and body and enable "read map tiles" in info and options tab. It works for me

  3. Just now, strzala said:

    I need script "use item on dead monster" please help me

     

    auto(100)

    local corpseIds = {5362, 5362} -- ids of bodies
    local itemIdToUse = 7803 -- id of the item to use on bodies

    function table.find(t, value)
      for k,v in pairs(t) do
        if v == value then return k end
      end
    end

    local tiles = g_map.getTiles()
    local corpses = {}
    for _, tile in pairs(tiles) do
        if tile:getPosition():getDistance(g_game.getLocalPlayer():getPosition()) <= 1 then
            local topItem = tile:getTopItem()
            if topItem and table.find(corpseIds, topItem:getId()) then
                table.insert(corpses, topItem)
            end
        end
    end

    if #corpses > 0 then
        for _, corpse in pairs(corpses) do
            setOption("Cavebot/Enabled", "false")
            g_game.stop()
            g_game.useItemOnPosition(itemIdToUse, corpse:getPosition())
            sleep(1000)
        end
    else
        setOption("Cavebot/Enabled", "true")
    end

     

  4. 1) Could you modify the below script so it's only using the spell if monsters are around 5sqm in any direction of our character (this is a target spell and with this script the bot is spamming this even if the target is far away)

    if g_game.isAttacking() then
      g_game.talk("spell 1")
      sleep(900, 1250)
    end
    auto(100)

     

    Thanks in advance

     

     

  5. I didnt want to create another thread so I'll just leave it here:

    setting area range in cavebot seem to not work. It always move in 1x1 area even when 3x3/5x5 is set or anything else. The bot always move the same path and when someone/something is blocking him, he would not move

  6. Just now, Zelek said:
    
    if not g_game.isOnline() then return end
    local messageToDetect = {"msgheck", "bot"}
    local lastMessage = g_game.lastTextMessage().message
    if not lastMessage then return end
    for v, k in pairs(messageToDetect) do
      if string.find(lastMessage, k, 1, true) then
        g_game.talk("im here") -- message to talk in default chat
        setOption("Global/BotPaused", "true")
        g_game.lastTextMessage().message = ""
        for i = 1, 5 do
          playSound("alarm.wav")
          sleep(1000)
        end
      end
    end
    auto(50)

    It may be that they changed how things works, but I highly doubt that.

    I'll let you know as soon as a banner checks me if it works

  7. 5 minutes ago, Zelek said:

    @lediv you can easily change the color of any message, it isn't an indicator of anything.

    ehh. But the bot has always been respodning to any messages and when banner checked me it did not so I dont know why is that - it's pretty weird then. A situtation when he didn't respond never happened to me before because I copied this script a few times so it responds to various messages from other players. That's why I thought it must be a system message but if it's not then well, sad, seems like it just doesnt work because it does not. dunno.

  8. On 2/11/2021 at 1:08 PM, Zelek said:

    I've already confirmed few months ago with a friend of one of the GMs at DBL that it is indeed a normal message, just without a name.

    We have used this script to determine it:

    
    
    print(#getTalkMessages())
    for v, k in pairs(getTalkMessages()) do
        if k.mode ~= 43 then
            print(v .. ": " .. k.sender .. ": " ..k.text)
        end
    end

    (Please mind that it's the previous api, but the internals didn't change)

    And we got this as a result:

    
    
    34: : [English] GM April is checking if you are using a bot. Please answer him on msgheck chat, on default chat or by private message.
    35: : [Polish] GM April sprawdza czy uzywasz bota. Prosimy abys odpowiedzial mu na msgcheck chacie, na default chacie lub w prywatnej wiadomosci.

    If it weren't a "talk message" it wouldn't appear in the logs.

     

  9. 9 minutes ago, Zelek said:

    As far as I know the bot check at DBL isn’t a system message, it’s normal message on a channel. If you want to check for system messages use g_game.lastTextMessage() instead. Maybe you were just unlucky and someone send a message on one of the open channels you had or you have sent a spell in the 50 millisecond window it takes it to refresh the script which would cause the last talk message to get overwritten.

    no the bot check in dbl is a system message (tho this system message that appers in red is caused when a banner uses specific command) but it's for sure not a normal massage. I'll try with this function you mentioned maybe it will work that way but where do I edit? which line?

  10. Hey I was finally able to test this msgheck script for dbl:

    if not g_game.isOnline() then return end
    local messageToDetect = {"msgheck", "bot"}
    local lastMessage = g_game.lastTalkMessage().message
    if not lastMessage then return end
    for v, k in pairs(messageToDetect) do
      if string.find(lastMessage, k, 1, true) then
        g_game.talk("im here") -- message to talk in default chat
        setOption("Global/BotPaused", "true")
        g_game.lastTalkMessage().message = ""
        for i = 1, 5 do
          playSound("alarm.wav")
          sleep(1000)
        end
      end
    end
    auto(50)

     

  11. 2 hours ago, Zelek said:
    
    auto(100)
    
    local corpseIds = {296, 4133} -- ids of bodies
    local itemIdToUse = 3456 -- id of the item to use on bodies
    
    function table.find(t, value)
      for k,v in pairs(t) do
        if v == value then return k end
      end
    end
    
    local tiles = g_map.getTiles()
    local corpses = {}
    for _, tile in pairs(tiles) do
        if tile:getPosition():getDistance(g_game.getLocalPlayer():getPosition()) <= 1 then
            local topItem = tile:getTopItem()
            if topItem and table.find(corpseIds, topItem:getId()) then
                table.insert(corpses, topItem)
            end
        end
    end
    
    if #corpses > 0 then
        for _, corpse in pairs(corpses) do
            setOption("Cavebot/Enabled", "false")
            g_game.stop()
            g_game.useItemOnPosition(itemIdToUse, corpse:getPosition())
            sleep(1000)
        end
    else
        setOption("Cavebot/Enabled", "true")
    end

     

    Remember to enable "Read map tiles" in Info & options tab.

    damn it really works, you're the best man

  12. 20 minutes ago, Zelek said:
    
    if getOption("Targeting/Enabled") == "true" and getOption("Cavebot/Enabled") == true then
    	setOption("Cavebot/WalkDelay", "200")
    elseif getOption("Targeting/Disabled") == "false" then
    	setOption("Cavebot/WalkDelay", "25")
    end
    auto(100)

     

    hmm It doesnt exactly work as I imagined, i forgot that targeting doesnt just switch off like that when the bot walks. Maybe there is a possibility to keep those walk delays but not with cavebot/targeting on/off but while we attack a monster and while we do not attack anything?

  13. If targetting enable and cavebot enable set walk delay with arrow keys to 200 if targeting disabled set arrow keys walk to 25 is that possible? It would make the bot look much more human-like with the new lure mode wchich is extremaly good new function

  14. 18 minutes ago, Zelek said:

    @lediv I believe I've fixed the issue in beta13b, let me know if you still have problems

    can't really test it. Now I get fatal errors all the time. But I'll keep on trying maybe it will eventually not crash I appreciate your trying in solving the problems

     

  15. this is one good example. The monster can attack us, but we cannot attack the monster and the bot will always stand there forever unless we set "reach" but if I set reach It will get buggy at the later point when he has to go up on another ladder because sometimes he will reach the monsters and miss the ladder by a few sqms

     

  16. 3 minutes ago, Zelek said:

    it targets monsters behind walls or whats the issue exactly? because the second sentence doesn’t make sense to me, if there is a distance monster then of course you have to set reach to get to it.

     

    I’ll take look at other things you have mentioned, thanks for the feedback

    I'll send you a screenshot of an example later because it's kinda hard to explain in words because the monster is not exacly behind the wall but it's impossible to attack it

  17. I'll list all the bugs I've already found with the new version

     

    1) when setting cavebot so the bot has to go upstairs and the targetting option is set to anything else than "no movement" sometimes he will miss the points with stairs or ladders because he will chase the monsters or soemthing and he will just stand a few sqm away from ladder/stairs forever - (that never occured in the previous bot update)

    2) both "target must be reachable" and "target must be shootable" doesnt work. Sometimes the bot will mark a monster (ones that hits us only from distance) and stand forever in one place unless we set "reach" in targetting

    3)Sometimes the bot will go up the ladder and immediately go down and he will remain standing there forever - also never happened to me in the previous bot version

    4) Condition healer doesnt save, I always have to set this up once I start the bot

     

    I am pretty sure 1* and 3* could be "easilly" fixed by a script (if character stuck for more than 10 seconds try to repeat previous cavebot step or start cavebot steps from the beggining if this is even possible

    If I'll find more bugs I'll edit the thread but I think you should look into those

     

  18. 55 minutes ago, Zelek said:

    @BlokuJr How about describing what's wrong exactly? Since it works perfectly fine for me and pretty much everyone else

    No it just doenst work properly, it crashes all the time and I've never had those issues before so he is kinda right

  19. 6 minutes ago, Zelek said:

    It should work, yes. Also this script does not have an option to respond to the message, it will only play an alarm for 5 seconds and pause the bot when the word has been detected in any message.

    Could you make it that so it automatically responds? It could be either on default chat or in the new opened window because it's completely useless without auto-respond. If I get a bot-check, not respond and the bot just stops activity it's 100% sure ban. That's the only thing I actually care about. Everything else is secondary

×
×
  • Create New...