futurepasts Posted July 30, 2015 Share Posted July 30, 2015 So my question is there any way to interact npc faster. What my script does is simply "Use" item in my inventory and clicks on npc and repeat till inventory is full, but it clicks every 1-2 seconds and thats slow code that i use. if (getInventory().isItemSelected()) { npc.interact("use"); } else { getInventory().interact("Use", "item name"); } Please answer understandable way cuz im newbie. Quote Link to comment Share on other sites More sharing options...
Developer Maxi Posted July 30, 2015 Developer Share Posted July 30, 2015 Maybe something like this? if (!inventory.isItemSelected()) { inventory.interact("Use", "item name"); if (!new ConditionalSleep(2000) { @Override public boolean condition() { return inventory.isItemSelected(); } }.sleep()) { return 10 + gRandom(5, 5); } } npc.interact("use"); 1 Quote Link to comment Share on other sites More sharing options...