Search the Community
Showing results for tags 'antiban'.
-
Hello everyone!! This is a free script available for use in script factory, downloadable from the script network. It completes the Draynor Village rooftop agility course. It does loot marks of grace. Hops worlds occasionally as well. If you do not start the script in Draynor, it will teleport to Draynor Village via Amulet of Glory, if you have one equipped. If you don't have an Amulet of Glory equipped, it will webwalk there. Edit to your liking and enjoy issues, bugs, questions, comments... pm me on discord ---> DROID#3850
-
- scriptfactory
- osbot
- (and 9 more)
-
I haven't been able to test anything, as I wrote this while the client is currently down. It works based on a weight system. Each action has a specific weight. The higher the weight, the more likely that action is to be performed. I only made 3 actions, but it's very simple to implement your own. Feedback is welcome. Adding your own action: Say you want to add an action to...check your woodcutting exp. You would add to the Action enum constants the name of the action and the default weight, like such: public enum Action { MOVE_MOUSE(3), ROTATE_CAMERA(7), RIGHT_CLICK_RANDOM_OBJECT(1), CHECK_WC_EXP(60); // <--------- int weight; Action(int weight) { this.weight = weight; } public int getWeight() { return weight; } public void setWeight(int weight) { this.weight = weight; } } Then you would add your method that performs the action to the switch statement in the execute() method, like so: switch (action) { case MOVE_MOUSE: script.log("[ANTI BAN:] Moving mouse."); moveMouseRandomly(); break; case ROTATE_CAMERA: script.log("[ANTI BAN:] Rotating camera."); rotateCameraRandomly(); break; case RIGHT_CLICK_RANDOM_OBJECT: script.log("[ANTI BAN:] Right-clicking an object"); rightClickRandomObject(); break; case CHECK_WC_EXP: script.log("[ANTI BAN:] Good luck JAGEX"); checkWcExp(); break; } Basic usage: import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; @ScriptManifest(author = "", info = "", logo = "", name = "Test", version = 0.1) public class Test extends Script { AntiBan antiban = new AntiBan(this, 30000, 180000); @Override public int onLoop() throws InterruptedException { if (antiban.shouldExecute()) { antiban.execute(); } return 500; } } Using a custom action list: import java.util.ArrayList; import java.util.List; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; import test.AntiBan.Action; @ScriptManifest(author = "", info = "", logo = "", name = "Test", version = 0.1) public class Test extends Script { AntiBan antiban; @Override public void onStart() { List<Action> actionList = new ArrayList<>(); // create an action with default weight Action action1 = Action.MOVE_MOUSE; // create an action and change its weight Action action2 = Action.ROTATE_CAMERA; action2.setWeight(20); // add actions to list actionList.add(action1); actionList.add(action2); // create antiban object with custom action list antiban = new AntiBan(this, 30000, 180000, actionList); } @Override public int onLoop() throws InterruptedException { if (antiban.shouldExecute()) { antiban.execute(); } return 500; } } Source:
- 12 replies