Juggles Posted August 12, 2018 Share Posted August 12, 2018 Has anyone else noticed a delay in the break condition? For example, if I set it to drink energy pots when below a certain run energy, it will pause for like 10 seconds before doing it. Is there a way around this or to remove the built in sleep? Here is my code. It won't try to drink until like 10seconds after the condition is met. if (getSettings().getRunEnergy()>=50 { WebWalkEvent webWalkEvent = new WebWalkEvent(INSIDE_BANK); webWalkEvent.setBreakCondition(new Condition() { @Override public boolean evaluate() { return getSettings().getRunEnergy()<50; } }); execute(webWalkEvent); } else { getInventory().interact("Drink","f->f.getName.contains("Energy")); } Quote Link to comment Share on other sites More sharing options...
Token Posted August 12, 2018 Share Posted August 12, 2018 Set the event execution mode to async, then do the condition checking and interrupt the event if needed from the main thread Quote Link to comment Share on other sites More sharing options...
Alek Posted August 12, 2018 Share Posted August 12, 2018 The break condition is checked on the beginning of a cycle. Quote Link to comment Share on other sites More sharing options...