Advertisement
Leffen

Untitled

Aug 29th, 2019
386
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.17 KB | None | 0 0
  1. // If bank interface is open deposit amulets and then withdraw bars
  2.         else if (getBank().isOpen()){
  3.             // If there is Ammy(u) in inv and also the mould then deposit all except the mould
  4.             if (getInventory().contains(GOLDAMMY) && getInventory().contains(AMULET_MOULD) ){
  5.                 // Deposits ammys, withdraws bars, sleeps, then pressses esc to close interface
  6.                 getBank().depositAllExcept(AMULET_MOULD);
  7.                 getBank().withdrawAll(GOLD_BAR);
  8.                 sleepWhile(() -> !getInventory().contains("Gold bar"), Calculations.random(500,1000));
  9.                 getKeyboard().typeSpecialKey(KeyEvent.VK_ESCAPE);
  10.             }
  11.             else {
  12.                 getBank().withdraw(AMULET_MOULD);
  13.                 sleepWhile(() -> !getInventory().contains("Gold bar"), Calculations.random(500, 1000));
  14.                 getBank().withdrawAll(GOLD_BAR);
  15.             }
  16.         }
  17.         // If bank interface is not open, open the closest
  18.         else {
  19.             walkToBank();
  20.             sleepWhile(() -> !getInventory().contains("Gold bar"), Calculations.random(500, 1000));
  21.             getBank().openClosest();
  22.  
  23.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement