function init(hero) {
    hero.setName("Ghost Rider");
    hero.setTier(10);
    
  
    hero.setHelmet("item.superhero_armor.piece.cowl");
    hero.setChestplate("item.superhero_armor.piece.jacket");
    hero.setLeggings("item.superhero_armor.piece.pants");
    hero.setBoots("item.superhero_armor.piece.boots");
    
    hero.addPowers("fiskheroes:healing_factor","fiskheroes:superhuman_durability", "fiskheroes:bullet_immunity",  "fiskheroes:explosion_immunity", "fiskheroes:fire_immunity", "fiskheroes:cold_resistance",  "pack:chain");
    hero.addAttribute("WEAPON_DAMAGE", 24, 0);
	hero.addAttribute("BASE_SPEED_LEVELS", 2.0, 0);
    hero.addAttribute("PUNCH_DAMAGE", 29, 0);
    hero.addAttribute("SPRINT_SPEED", 0.45, 1);
    hero.addAttribute("FALL_RESISTANCE", 100.0, 0);
    hero.addAttribute("JUMP_HEIGHT", 1.7, 1);
    
	
		
	
	
	
	
   hero.addKeyBind("SUPER_SPEED", "Summon Bike", 2);
    hero.addKeyBind("TENTACLE_JAB", "Hellfire Chain Jab", 5);
    hero.addKeyBind("TENTACLE_GRAB", "Hellfire Chain Grab", 4);
    hero.addKeyBind("TENTACLES", "Hellfire Chain", 3);
    hero.addKeyBind("AIM", "Flamethrower", 1);
    

    hero.supplyFunction("canAim", canAim);
    
    hero.setDamageProfile(getDamageProfile);
    hero.addDamageProfile("FLAME_PUNCH", {
        "types": {
            "BLUNT": 1.0,
            "FIRE": 0.4
        },
        "properties": {
            "HEAT_TRANSFER": 40,
            "IGNITE": 2
        }
    });


	hero.addSoundEvent("STEP", "pack:bike_moving");
	

	hero.addAttributeProfile("BIKE_PROFILE", bikeProfile);
	 hero.setAttributeProfile(getProfile);

}


function getDamageProfile(entity) {
    return entity.getHeldItem().isEmpty() ? "FLAME_PUNCH" : null;
}


function canAim(entity) {
    return entity.getHeldItem().isEmpty() && !entity.getData("fiskheroes:jetpacking");
}


function bikeProfile(profile) {
    profile.addAttribute("PUNCH_DAMAGE", -1.0, 1);
	profile.addAttribute("STEP_HEIGHT", 0.5, 0);
	profile.addAttribute("BASE_SPEED", -1.0, 1);
	profile.addAttribute("BASE_SPEED_LEVELS", 4.0, 0);
	profile.addAttribute("SPRINT_SPEED", 0.75, 1);
	profile.addAttribute("JUMP_HEIGHT", 1.5, 0);
	 
}


function getProfile(entity) {
    if (entity.getData("fiskheroes:speeding")) {
        return "BIKE_PROFILE";
    }
}
