Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as Java by Ib4rr0wI ( 16 years ago )
/*
 * Ok, I still can't figure out how to let this thing chop a tree.
 * I want it to chop anything thats in range, and if its not you level it wont chop it 
 * until it has reached the req. level i know its something with 
 * public boolean chopTree(){   or am i wrong? and what about the public void, 
 * thanks btw i understand it much better now. is there a code like
 * public void atTree (){
 * if(clickNearestRSobjectByRandomizedID(TreeID)
 * this is probably the worst method you've ever seen.
 * well thanks anyways and i hope you can help me further
 */
import java.awt.*;
import java.util.*;
import java.util.List;
import java.util.logging.Level;
import javax.accessibility.*;
import javax.swing.*;

import org.rsbot.bot.Bot;
import org.rsbot.script.*;
import org.rsbot.script.wrappers.*;
import org.rsbot.accessors.*;
import org.rsbot.event.listeners.PaintListener;
import org.rsbot.event.listeners.ServerMessageListener;
import org.rsbot.event.events.ServerMessageEvent;
import org.rsbot.util.ScreenshotUtil;

@ScriptManifest(authors = { "Ib4rr0wI" }, category = "Woodcutting", name = "iBwoodcutter", version = 1.00, description = "<html><head></head><body>Script description here.</body></html\n")
public class iBwoodcutter extends Script implements PaintListener, ServerMessageListener {

    private final ScriptManifest properties = getClass().getAnnotation(ScriptManifest.class);


    int axeID = 12345; 

    public boolean onStart(Map<String, String>args){
 return true;
}
    public void serverMessageRecieved(final ServerMessageEvent arg0) {
        final String serverString = arg0.getMessage();
    }
        


public boolean needToDrop() {
 if(isInventoryFull());
 return true;
 }

public boolean walkToTree(){
 return true;
}

public boolean atTree(){
 return true;
}

public boolean chopTree(){
 return true;
}

 @Override
 public int loop() {
  
  
  
  public void dropAllExceptAxe(){
   if(needToDrop()){
    dropAllExceptAxe(axeID);
    log("you killed them!");
   }
   else{
    log("Keep chopping!")
  }
   return 0;
 }

}
 

       
    public void onFinish() {
        ScreenshotUtil.takeScreenshot(true);
    }
}

 

Revise this Paste

Your Name: Code Language: