function init(hero) {
    hero.setName("Joker");
    hero.setTier(6);
    
    hero.setHelmet("Hair");
    hero.setChestplate("Chestplate");
    hero.setLeggings("Leggings");
    hero.setBoots("Boots");
    hero.addPrimaryEquipment("fiskheroes:desert_eagle", true, item => !item.nbt().getBoolean("Dual"));
	
    hero.addPowers("tgheroes:jokes");
    hero.addAttribute("PUNCH_DAMAGE", 6.0, 0);
    hero.addAttribute("WEAPON_DAMAGE", 4.0, 0);
    hero.addAttribute("JUMP_HEIGHT", 2.5, 0);
    hero.addAttribute("FALL_RESISTANCE", 1.0, 1);
    hero.addAttribute("SPRINT_SPEED", 0.3, 1);
    
    hero.addKeyBind("CHARGED_BEAM", "Joke Flower", 4);
	hero.addKeyBind("BLADE", "Draw Knife", 3);
    hero.addKeyBind("UTILITY_BELT", "Jokes", 2);
	hero.addKeyBind("AIM", "key.aim", -1);
    hero.addKeyBind("GUN_RELOAD", "key.reload", 1);

    hero.setKeyBindEnabled((entity, keyBind) => keyBind != "GUN_RELOAD" || entity.getHeldItem().isGun() && !entity.getData("fiskheroes:aiming"));
    hero.supplyFunction("canAim", entity => entity.getHeldItem().isGun());
    hero.setHasPermission(hasPermission);

    hero.addAttributeProfile("BLADE", battonstProfile);
    hero.setAttributeProfile(getProfile);
    hero.setDamageProfile(getProfile);
    hero.addDamageProfile("BLADE", {"types": {"SHARP": 1.0}});	
}

function battonstProfile(profile) {
    profile.inheritDefaults();
    profile.addAttribute("PUNCH_DAMAGE", 12, 0);
    profile.addAttribute("REACH_DISTANCE", 0.0, 0);
}

function getProfile(entity) {
    return entity.getData("fiskheroes:blade") ? "BLADE" : null;
}

function hasPermission(entity, permission) {
    return  permission == "USE_GUN";
}

