Advertisement
Guest User

Untitled

a guest
Sep 26th, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. import org.rsbot.script.ScriptManifest;
  2. import org.rsbot.script.Script;
  3. import org.rsbot.script.wrappers.RSObject;
  4.  
  5. @ScriptManifest(authors = { "kaas" }, keywords = { "kaas" }, name = "test", version = 1.0, description = "kaas")
  6. public class Test extends Script {
  7.  
  8. private int TREE = 1278;
  9. private int RUNE_HATCHET = 1359;
  10.  
  11. public boolean onStart(){
  12. return true;
  13. }
  14.  
  15. public int loop(){
  16. if(inventory.isFull()){
  17. inventory.dropAllExcept(RUNE_HATCHET);
  18. }else{
  19. if(get my player().getAnimation() != 867) {
  20. RSObject tree = objects.getNearest(TREE);
  21. if(tree != null){
  22. tree.doAction("chop");
  23. sleep (500, 800);
  24. }
  25. }
  26. }
  27. return random(100, 200);
  28. }
  29.  
  30. public void onFinish(){
  31.  
  32. }
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement