Jump to content

Butters

Lifetime Sponsor
  • Posts

    650
  • Joined

  • Last visited

  • Feedback

    100%

Everything posted by Butters

  1. Depends on how Alek is busy. He needs to check your script, approve stuff and etc. Took me about 2 weeks I think.
  2. Hey, So as I noticed widget debug doesn't work on the login screen and I want to combat that pesky "Login limit exceeded" message, anyone know the best way to do it? Maybe there's something else apart colour grabbing? Cheers
  3. Cause the first thing OSBot does is do stuff in onStart() method, then loops your logic in onLoop() method. You fetch the fishing spot only when the class is initialized (which will be null). You want to find your npcs in the onLoop() method.
  4. Just download Oracle Java and you'll be covered in all scenarios
  5. To my understanding, when osbot starts with -debug flag it starts a socket server on the specified port. So if OSBot is not running - you don't have where to connect. All fine and dandy, though somehow the inputStream is empty and doesn't provide me the log messages. All nulls. Maybe someone who messed around with this more could enlighten us?
  6. Somehow the input stream is empty even though the bot is running and I connected successfully. Any ideas? Connected to the correct port ofc.
  7. Thanks, will try this out. Somehow didn't think that OSBot runs a socket server for this
  8. Hey, I;m having trouble debugging my system and need help getting the full log of what's going on. I'm using Linux and run quite a few bots on one machine. I wanted to either redirect all bot output logs to certain files or to keep the terminals open after the bot dies (this is the way I made stuff - kill the bot when it's done with System.exit(0);) 1. Grabbing output from a known debug port Let's say bot uses debug port 5011. Tried using nc to listen for output on the mentioned port, though says that the port is already being used. Any better tools out there? 2. Keeping the terminal alive after bot dies I start bots on their own terminal each time, using something like "xterm -e java -jar osbot.jar ........." Now when the bot dies, the terminal closes, and bye bye all logs, error messages and etc. I noticed that after osbot handles the login info it launches a new process or something to start the bot client so something like "xterm -hold -e java -jar osbot.jar...." or "xter -e "java -jar osbot.jar;read" doesn't work as it stops doing stuff adter the login screen (even when I bypass it with -login flag), So any ideas how to solve this? In short I think I get some error message when I start a bot and I dunno what happened, the terminal closes immediatelly, overrding the log() method didn't help much either.
  9. So no ideas how to prevent this without doing woodoo stuff?
  10. if (inventory.contains("Steel nails") && inventory.getAmount("Steel nails") >= 10) { do something funky }
  11. Yeah that's why I started using interaction event with setMaximumAttemps(1). Usually spammed trade requests like hell.
  12. Sadly it did. Log looked something like: [log message - action| Interaction event failed - didn't trade Interaction event failed - didn't trade Interaction event failed - trade sent somehow
  13. Was testing stuff with interaction event and can't get my head around the hasFailed() and hasFinished() methods. Snippet below: Player worker = s.players.closest(tradeArea, workerName); if (worker != null) { InteractionEvent e = new InteractionEvent(worker, "Trade with"); e.setHover(false); e.setMaximumAttempts(1); e.setOperateCamera(true); s.execute(e); Utils.condSleep(5000, 300, () -> e.hasFinished() || e.hasFailed()); if (e.hasFinished()) { s.log("Interaction even has finished and will sleep!!!"); Utils.condSleep(20000, 500, () -> s.trade.isFirstInterfaceOpen()); } if (e.hasFailed()) s.log("Interaction event failed!!!!!!!"); } As you can see this is for trading. It seems that hasFinished() == true when the event succeeds (doesn't fail), hasFailed() == when it fails to eventually send a trade request. The problem I'm facing is that the hasFailed() method sometimes fires even if it actually succeeds (sent a trade request). Is this a bug or am I doing something wrong?
  14. I reckon you're talking about the same problem PulseImpulse and magerange had. This launcher runs on JavaFX, which is a seperate library for the GUI part. If you're running it on Linux with something like OpenJDK then it shouldn't work out of the box. Install Oracle JDK for best results. If it fails to launch, try to launch it via command line with "java -jar explv_bot_manager.jar" or something and post what error you get.
  15. It's more of a philosophical question though more or less works as you mentioned, apart I still wouldn't call it "human like". Probably never gonna know all the slight details in a changing environment, so best bet would be to implement AI and teach the system. Just thoughts though.
  16. new ConditionalSleep(timeout, delay) { @Override public boolean condition() throws InterruptedException { return b.asBoolean(); } }.sleep(); This little thing here. It says sleep for a maximum time of TIMEOUT and check every DELAY time if the CONDITION is true. Now when you pass 10000, 200, false as parameters it means that, hey sleep for 10 seconds and check every 200ms if true == false, which will never be true, so it will sleep for 10 seconds. The boolean you pass is a "constant" let's say. Bolean supplier "fetches" the true/false result from the CONDITION whenever it's invoked. So it will check if it's true/false every 200ms in your case.
  17. You're passing the boolean as false condSleep(10000, 200, trade.isCurrentlyTrading()); This means it will sleep for 10 seconds every time. You need to pass a boolean supplier like so: log("before cond"); log(trade.isCurrentlyTrading()); // returns false, as expected condSleep(10000, 200, () -> trade.isCurrentlyTrading()); log("after cond"); log(trade.isCurrentlyTrading()); // returns true, as expected // also in the class private void condSleep(int timeout, int delay, BooleanSupplier b) { new ConditionalSleep(timeout, delay) { @Override public boolean condition() throws InterruptedException { return b.asBoolean(); } }.sleep(); }
  18. Kinda strange regarding that deleting data about banned accounts would be insanely unwise.
  19. Lol exactly
  20. Just add a "-"to all oh the mentioned response codes and bingo
  21. Try to use the depositBox.interact(int slot, String actions) method. The action will probably be Deposit. To achieve this you can just randomize from 1 to 28 (or from 0 to 27 - please check from where it starts counting). Just a simple example, just add some decent randomness int[] slots = new int[4] {1. 4, 8, 9}; for (int slot : slots) { depositBox.interact(slot, "Deposit"); }
  22. Never happened to me tbh. Though the main cause I would say is lag. if (trade.isFirstInterfaceOpen() { // DO Trade trade.acceptTrade(); } else if (trade.isSecondInterfaceOpen()) { trade.acceptTrade(); } Using more or less this structure
  23. I really doubt that OSBot isn't allowing for GC to work As my scripts go, I thought they were the cause of memory leaks, though checked and rechecked and didn't find anything. Doesn't mean that I'm any good at identifying these though
  24. Just blabbing, but after webwalking it doesn't drop down to previous RAM usage. Dunno if this is normal. Eventually had a ton of problem with memory management, though using -mem 1024 flag seemed to help.
×
×
  • Create New...