Пример #1
0
  /**
   * Sets withdraw mode - true for noted items, false for un-noted
   *
   * @param which
   */
  private void withdrawNote(boolean which) {
    if (!isOpen()) return;

    IComponent n = botEnv.interfaces.getComponent(BANK_INTERFACE_ID, BANK_BUTTON_NOTE);
    if (n == null) return;
    if (which) {
      // Set to withdraw-notes
      if (n.getTextureID() != 1433) n.doClick();
    } else {
      if (n.getTextureID() != 1431) n.doClick();
    }
  }
Пример #2
0
  /**
   * @param depositType Inventory, equipment, or familiar.
   * @return
   */
  private boolean depositByButton(int depositType) {
    if (!isOpen()) return false;

    IComponent depButton = botEnv.interfaces.getComponent(Bank.BANK_INTERFACE_ID, depositType);
    if (depButton != null && depButton.isVisible()) {
      if (depButton.doClick()) {
        sleep(300, 500);
        return true;
      }
    }

    return false;
  }
Пример #3
0
 /** Closes the bank interface. */
 public void close() {
   IComponent close = botEnv.interfaces.getComponent(762, BANK_BUTTON_CLOSE);
   if (close != null && isOpen()) {
     close.doClick();
   }
 }