W00P, about 5 hours ago I finished my first bot
Granite miner bot. Doesn't bank for waterskins but it does have antiban/checks if your invent has waterskins/drops empty ones/power mines. Doesn't support water tiara and basically is a massive fail but it works! W00P
also it's not leached off a tutorial which makes me feel proud
Granite miner bot. Doesn't bank for waterskins but it does have antiban/checks if your invent has waterskins/drops empty ones/power mines. Doesn't support water tiara and basically is a massive fail but it works! W00P
Code:
import org.rsbot.script.Script;
import org.rsbot.script.ScriptManifest;
import org.rsbot.script.wrappers.RSObject;
@ScriptManifest(
authors = {"Automatic Coding"},
version = 0.01,
keywords = {""},
description = "Granite miner",
name = "Granite miner"
)
public class AutoGranite extends Script {
int oreID = 10947;
int miningAnimation = 624;
public boolean onStart() {
return true;
}
@Override
public int loop() {
antiBan();
if(inventory.containsOneOf(1825, 1823, 1827, 1829)) {
if(inventory.isFull()){
inventory.dropAllExcept(1823, 1825, 1827, 1829);
} else {
mineOres();
}
} else {
stopScript(true);
}
return random(300,500);
}
public void onFinish() {
log("Thank you for using my script!");
}
private void mineOres() {
if(getMyPlayer().getAnimation() != miningAnimation){
RSObject rock = objects.getNearest(oreID);
rock.doAction("Mine");
sleep(1000,1800);
}
}
private void antiBan() {
int r = random (0,100);
switch(r) {
case 3:
mouse.moveSlightly();
sleep(200,800);
break;
case 74:
mouse.moveOffScreen();
sleep (1000,3000);
break;
case 54:
camera.moveRandomly(random(750,1250));
break;
}
}
}
also it's not leached off a tutorial which makes me feel proud
