var scriptName = "AutoL";
var scriptVersion = 1.0;
var scriptAuthor = "hh";

var CNM = ["Your client is trash target.getName().", "You are a sigma user target.getName()."];
var target;
   
var EntityPlayer = Java.type('net.minecraft.entity.player.EntityPlayer');
var S02PacketChat = Java.type('net.minecraft.network.play.server.S02PacketChat')

function AutoL() {
    this.getName = function () {
        return "AutoL";
    };

    this.getDescription = function () {
        return "";
    };

    this.getCategory = function () {
        return "Misc";
    };
	
	this.getTag = function() {
		return "AquaBounce";
	}
	
    this.onEnable = function () {
		target = null;        
    };


    
    this.onAttack = function (event) {
		if(event.getTargetEntity() instanceof EntityPlayer){
			target = event.getTargetEntity();
		}

    };

    this.onUpdate = function () {		
        if (target != null) {
            if (target.isDead) {
                mc.thePlayer.sendChatMessage("[" + "AquaBounce" + "]" + " " + " " + " " +CNM[parseInt(Math.random()*CNM.length)] );
                target = null;
            }
        }
		
    };

}

var AutoLModule = new AutoL();

var AutoLModuleClient;

function onLoad() {

}

function onEnable() {
    AutoLModuleClient = moduleManager.registerModule(AutoLModule);
}

function onDisable() {
    moduleManager.unregisterModule(AutoLModuleClient);
}