zakne11 Posted January 30, 2021 Share Posted January 30, 2021 21 hours ago, asktheages said: Hello! Im very happy with your bot. Unfortunately i lack scripting skills. Thats why i ask for one. I need a script that pauses every activity of the bot, when character leaves certain X Y box. If the character leaves it, script plays alarm. Also, after a little delay it presses a button (f1-f12). End. To explain it better - if GM tp's me out of my respawn when i cavebot to another resp with same monsters, the bot will run ASAP to them. This is a sure ban, as human player would never act like this. He would stay and write some "??". I had it on blackd back in the days. Thanks! local x = local y = local z = pos = g_game.getLocalPlayer():getPosition() if pos.x ~= x or pos.y ~= y or pos.z ~= z then playSound("alarm.wav") if getOption("Global/BotPaused") == "false" then setOption("Global/BotPaused", "true") sleep(300000) end if getOption("Global/BotPaused") == "true" then setOption("Global/BotPaused", "flase") end end auto(500) Link to comment Share on other sites More sharing options...
lediv Posted January 30, 2021 Share Posted January 30, 2021 9 hours ago, asktheages said: Also - if the script for MsgCheck on dbl doesnt work - is there a way for you to make a script that interracts with the chat window that opens - and based on that alarm player? Or some other creative way to get alarmed on MsgCheck? As for now, there is no way to use the bot safely... He stated that it will work in the future update because now the bot does not properly read system messages at the moment Link to comment Share on other sites More sharing options...
victinhods Posted February 4, 2021 Share Posted February 4, 2021 (edited) Its possible some script to check task? 17/200 Monster Killeds -> Check this msg in Default Channel Exemp: when 200/200 go to label "x" in cavebot Edited February 4, 2021 by victinhods Link to comment Share on other sites More sharing options...
zakne11 Posted February 4, 2021 Share Posted February 4, 2021 5 hours ago, victinhods said: Its possible some script to check task? 17/200 Monster Killeds -> Check this msg in Default Channel Exemp: when 200/200 go to label "x" in cavebot local TextToFind = xxx local FoundMessage = false for k,v in pairs(g_game.getTextMessages()) do if v = TextToFind then return FoundMessage = true end end if FoundMessage then gotolabel("HUNTING", "start-hunting") end 1 Link to comment Share on other sites More sharing options...
victinhods Posted February 4, 2021 Share Posted February 4, 2021 (edited) @Zelek its possible Create a channel with some hotkeys to make scripts 100% afk?1. Check position, Potions, Cap, money to "buy", 2. Travel Npc 3. Sell items 4. Buy Potions 4. Deposit Items Edited February 4, 2021 by victinhods 1 Link to comment Share on other sites More sharing options...
215609 Posted February 4, 2021 Share Posted February 4, 2021 3 hours ago, victinhods said: @Zelek its possible Create a channel with some hotkeys to make scripts 100% afk?1. Check position, Potions, Cap, money to "buy", 2. Travel Npc 3. Sell items 4. Buy Potions 4. Deposit Items and check potions, check cap, for leave hunt Link to comment Share on other sites More sharing options...
lediv Posted February 4, 2021 Share Posted February 4, 2021 On 11/10/2020 at 1:52 PM, Zelek said: 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 setOption("Global/BotPaused", "true") g_game.lastTalkMessage().message = "" for i = 1, 5 do playSound("alarm.wav") sleep(1000) end end end auto(50) will it now work in dbl after this new update? and do we put what he has to respond between " " after g_game.lasttalMessage().message =" "?? Link to comment Share on other sites More sharing options...
Zelek Posted February 4, 2021 Author Share Posted February 4, 2021 1 hour ago, lediv said: will it now work in dbl after this new update? and do we put what he has to respond between " " after g_game.lasttalMessage().message =" "?? 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. Link to comment Share on other sites More sharing options...
lediv Posted February 4, 2021 Share Posted February 4, 2021 (edited) 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 Edited February 4, 2021 by lediv Link to comment Share on other sites More sharing options...
Mojzesz Posted February 4, 2021 Share Posted February 4, 2021 If possible, I would like a script that searches the entire screen for items whose id is contained in an array. I just need to search on the surface, z =7. Thank you in advance! Link to comment Share on other sites More sharing options...
Zelek Posted February 5, 2021 Author Share Posted February 5, 2021 27 minutes ago, Mojzesz said: If possible, I would like a script that searches the entire screen for items whose id is contained in an array. I just need to search on the surface, z =7. Thank you in advance! local idsToFind = {3031, 3035} local tiles = g_map.getTiles() for _, tile in pairs(tiles) do local topItem = tile:getTopItem() if topItem then for _, id in pairs(idsToFind) do if topItem:getId() == id then playSound("alarm.wav") break end end end end auto(100) Remember to enable the "read map tiles" box in info & options tab. Also reading tiles is limited to the current floor you are at the moment. I'm looking into expanding this tho. 1 1 Link to comment Share on other sites More sharing options...
Mojzesz Posted February 5, 2021 Share Posted February 5, 2021 (edited) 10 minutes ago, Zelek said: local idsToFind = {3031, 3035} local tiles = g_map.getTiles() for _, tile in pairs(tiles) do local topItem = tile:getTopItem() if topItem then for _, id in pairs(idsToFind) do if topItem:getId() == id then playSound("alarm.wav") break end end end end auto(100) Remember to enable the "read map tiles" box in info & options tab. Also reading tiles is limited to the current floor you are at the moment. I'm looking into expanding this tho. So I now understand why the one I wrote myself didn't work for me, it's just that the search on other floors is not yet implemented. Will this be hard to implement? When can we expect to add searching of other floors? To tell the truth, for me this is the most important function. Edited February 5, 2021 by Mojzesz Link to comment Share on other sites More sharing options...
victinhods Posted February 5, 2021 Share Posted February 5, 2021 10 hours ago, 215609 said: and check potions, check cap, for leave hunt @Zelek Please, check this Link to comment Share on other sites More sharing options...
shirako Posted February 5, 2021 Share Posted February 5, 2021 (edited) Hey, I was using a simple script which was Quote auto(250) g_game.talk("charge") wait(25000) I was using this script since its toggable that means support spams it instead of casting it once. I tried replacing wait with sleep but it doesnt seem to work can you create a replacement for me zelek :)? Edited February 5, 2021 by shirako Link to comment Share on other sites More sharing options...
Zelek Posted February 5, 2021 Author Share Posted February 5, 2021 7 minutes ago, shirako said: Hey, I was using a simple script which was I was using this script since its toggable that means support spams it instead of casting it once. I tried replacing wait with sleep but it doesnt seem to work can you create a replacement for me zelek :)? if you replace wait with sleep it definitely should work Link to comment Share on other sites More sharing options...
lediv Posted February 5, 2021 Share Posted February 5, 2021 (edited) 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 Edited February 5, 2021 by lediv Link to comment Share on other sites More sharing options...
Zelek Posted February 5, 2021 Author Share Posted February 5, 2021 33 minutes ago, lediv said: 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 if getOption("Targeting/Enabled") == "true" and getOption("Cavebot/Enabled") == "true" then setOption("Cavebot/WalkDelay", "200") elseif getOption("Targeting/Enabled") == "false" then setOption("Cavebot/WalkDelay", "25") end auto(100) Link to comment Share on other sites More sharing options...
lediv Posted February 5, 2021 Share Posted February 5, 2021 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? Link to comment Share on other sites More sharing options...
Zelek Posted February 5, 2021 Author Share Posted February 5, 2021 1 minute ago, lediv said: 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? if g_game.isAttacking() then setOption("Cavebot/WalkDelay", "200") else setOption("Cavebot/WalkDelay", "25") end auto(100) 1 Link to comment Share on other sites More sharing options...
Gregorian Posted February 6, 2021 Share Posted February 6, 2021 (edited) I can't search in forum scrypt for targeting on/off in hotkeys. Edited February 6, 2021 by Gregorian Link to comment Share on other sites More sharing options...
Zelek Posted February 6, 2021 Author Share Posted February 6, 2021 44 minutes ago, Gregorian said: I can't search in forum scrypt for targeting on/off in hotkeys. if getOption("Targeting/Enabled") == "true" then setOption("Targeting/Enabled", "false") else setOption("Targeting/Enabled", "true") end Above script will make the bot non responding, please don't use getOption and setOption in hotkeys until I fix that. Link to comment Share on other sites More sharing options...
victinhods Posted February 6, 2021 Share Posted February 6, 2021 @Zelek Please, this community need some scripts to make scripts 100% afk... so if you can help us! some scripts: Check Task Check Cap/Potion Refil Pot Travel NPC Sell Loot Deposit Items Link to comment Share on other sites More sharing options...
lediv Posted February 6, 2021 Share Posted February 6, 2021 (edited) j Edited February 14, 2021 by lediv Link to comment Share on other sites More sharing options...
victinhods Posted February 7, 2021 Share Posted February 7, 2021 I need this hotkey... if idletiime => 20 seconds gotolabel xxxx Link to comment Share on other sites More sharing options...
asktheages Posted February 7, 2021 Share Posted February 7, 2021 On 1/30/2021 at 7:28 PM, zakne11 said: local x = local y = local z = pos = g_game.getLocalPlayer():getPosition() if pos.x ~= x or pos.y ~= y or pos.z ~= z then playSound("alarm.wav") if getOption("Global/BotPaused") == "false" then setOption("Global/BotPaused", "true") sleep(300000) end if getOption("Global/BotPaused") == "true" then setOption("Global/BotPaused", "flase") end end auto(500) Dear Zelek, Could you tell me how to set the X Y Z properly? If i put a certain value it wont work as intended. I need a range - lets say X range 931 - 999 , Y - 700-750 (so the box goes around all the respawn where i cavebot). Thanks Link to comment Share on other sites More sharing options...
Recommended Posts