Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1. public class Fletch implements Condition, Task {
- 2.
- 3. @Override
- 4. public void run() {
- 5. //boolean isFletching = false;
- if(Players.getLocal().isMoving() && Players.getLocal().getAnimation() != -1) {
- 7. for (Item i : Inventory.getItems()) {
- 8. i.getName().contains("Logs");
- 9. i.getWidgetChild().interact("Craft");
- 10. log.info("Fletching logs and making arrow shafts...");
- 11. Time.sleep(2000);
- 12.
- 13. if (Widgets.get(1179, 12).isVisible()) {
- 14. Widgets.get(1179, 12).click(true);
- 15. Time.sleep(1000);
- 16.
- 17. if (Widgets.get(905, 14).isVisible()) {
- 18. Widgets.get(905, 14).click(true);
- 19. //isFletching = true;
- 20. Time.sleep(2000);
- 21.
- 22. }
- 23. }
- 24. }
- 25. }
- 26. }
- 27.
- 28. @Override
- 29. public boolean validate() {
- 30. return Inventory.getCount() == 28 && !isBusy();
- 31. }
- 32.
- 41.
- 42. }
Add Comment
Please, Sign In to add comment