Slayer base

Discussion in 'RuneScape Miscellaneous' started by Axed1, Dec 24, 2009.

Thread Status:
Not open for further replies.
Slayer base
  1. Unread #1 - Dec 24, 2009 at 3:50 AM
  2. Axed1
    Joined:
    Apr 15, 2009
    Posts:
    1
    Referrals:
    0
    Sythe Gold:
    0

    Axed1 Newcomer

    Slayer base

    Here I was bored, and thought you guys could use a base :p, there is no anti-leech and don't say I didn't make this without proof and don't flame me please.

    Code:
    package core.skills;
    
    import core.players.Player;
    
    public class slayerClass {
    	
    	private int task;
    	private int amount;
    	public int[][] appendData = {
    			{1, 200, 90}
    	};
    	
    	public void proceedtoSlayer(Player p) {
    		if(!p.slayerTask) {
    			setTask(getRandomTasks(1));
    			setAmount(getRandomAmount());
    			p.frames.sendMessage(p, "You have just recevied a slayer task and it is " + task + ".");
    			p.frames.sendMessage(p, "You have to kill " + amount);
    		}
    		if(p.slayerTask) {
    			getFinishedTask(p);
    		}
    		resetSlayer(p);
    	}
    
    	private void getFinishedTask(Player p) {
    		if(amount < 1) {
    			p.frames.sendMessage(p, "You have finished your slayer task, please return to a Slayer Master ");
    			p.frames.sendMessage(p, "to get a new one.");
    		}
    		p.frames.sendMessage(p, "You have not completed your slayer task, please comeback when you have!");
    	}
    
    	private void resetSlayer(Player p) {
    		task = 0;
    		amount = 0;
    		p.slayerTask = false;
    	}
    
    	private int getRandomAmount() {
    		return appendData[(int)(Math.random() * (appendData.length))][0];
    	}
    
    	private int getRandomTasks(int range) {
    		return (int) (Math.random() * (range + 1));
    	}
    
    	public void setAmount(int amount) {
    		this.amount = amount;
    	}
    
    	public int getAmount() {
    		return amount;
    	}
    
    	public void setTask(int task) {
    		this.task = task;
    	}
    
    	public int getTask() {
    		return task;
    	}
    
    }
     
  3. Unread #2 - Dec 28, 2009 at 11:49 AM
  4. jdwk 7
    Joined:
    Oct 4, 2008
    Posts:
    181
    Referrals:
    0
    Sythe Gold:
    0

    jdwk 7 Active Member
    Banned

    Slayer base

    Is the base private?
     
< project-ffx 508 pking | Any server out there for? >

Users viewing this thread
1 guest
Thread Status:
Not open for further replies.


 
 
Adblock breaks this site