//AIO gem cutter v1
//Banks at most bankers
//Made for public use
//Made for ReflectionBot2.5
//Cuts Sapphires, Emeralds, Rubys, Diamonds, & Dragonstones
package scripts;
import bot.Bot;
import bot.Script;
import javax.swing.JOptionPane;
public class CutStoner extends Script implements Runnable {
private int itemToWithdraw;
private int itemToDeposit;
public void init(String params) {
System.out.println("..::StonerCuts~::.. by Vistaster");
}
private int loop() throws Exception {
if (invContains(itemToWithdraw)) {
if (!rf.isSleeping()) {
useItemOnItem(itemToWithdraw, 167);
return (random(610, 800));
}
} else {
if (bankOpen()) {
withdraw(itemToWithdraw, 28);
wait(random(650, 800));
depositAll(itemToDeposit);
wait(random(650, 800));
return (600);
} else {
openBank();
return (2000);
}
}
return 800;
}
public void start() {
Object[] options = { "Sapphire", "Emerald", "Ruby",
"Diamond", "Dragonstone"};
String res1 = (String) JOptionPane.showInputDialog(null, "",
"CutStoner by Vistaster:: Choose gem type", JOptionPane.PLAIN_MESSAGE, null, options,
options[0]);
if (res1.equals("Sapphire")) {
itemToWithdraw = 160;
itemToDeposit = 164;
} else if (res1.equals("Emerald")) {
itemToWithdraw = 159;
itemToDeposit = 163;
} else if (res1.equals("Ruby")) {
itemToWithdraw = 158;
itemToDeposit = 162;
} else if (res1.equals("Diamond")) {
itemToWithdraw = 157;
itemToDeposit = 161;
} else if (res1.equals("Dragonstone")) {
itemToWithdraw = 542;
itemToDeposit = 523;
}
scriptThread = new Thread(this);
initialize();
}
public void run() {
while (Bot.scriptRunning) {
try {
if (rf.isLoggedIn() && !rf.isSleeping())
Thread.sleep(loop());
else Thread.sleep(200);
} catch (Exception e) {
e.printStackTrace();
}
}
}
public void stop() {
kill();
}
}