/** * Drops the inventory item of the specified column and row. * * @param col the column the inventory item is in * @param row the row the inventory item is in */ public static void dropItem(int col, int row) { if (col < 0 || col > 3 || row < 0 || row > 6) return; if (getAllItems()[col + row * 4].getId() == -1) return; Point p; p = Mouse.getLocation(); if (p.x < 563 + col * 42 || p.x >= 563 + col * 42 + 32 || p.y < 213 + row * 36 || p.y >= 213 + row * 36 + 32) { Mouse.move(getComponent().getComponents()[row * 4 + col].getCenter(), 10, 10); } Mouse.click(false); Task.sleep(Random.nextInt(10, 25)); Menu.click("Drop"); Task.sleep(Random.nextInt(25, 50)); }