function init(hero) {
    hero.setName("Black Adam");
    hero.setVersion("DCEU");
    hero.setTier(9);
    
    hero.setChestplate("item.superhero_armor.piece.chestpiece");
    hero.setLeggings("item.superhero_armor.piece.pants");
    hero.setBoots("item.superhero_armor.piece.boots");
    
    hero.addPowers("fiskheroes:divine_empowerment");
    hero.addAttribute("PUNCH_DAMAGE", 10, 0);
    hero.addAttribute("BASE_SPEED_LEVELS", 2.0, 0);
    
    hero.addKeyBind("SUPER_SPEED", "key.superSpeed", 1);
    
    hero.setDefaultScale(1.1);
    hero.setModifierEnabled(isModifierEnabled);
    
    hero.setDamageProfile(getDamageProfile);
    hero.addDamageProfile("PUNCH", {
        "types": {
            "BLUNT": 1.0,
            "MAGIC": 0.7
        }
    });
}

function getDamageProfile(entity) {
    return !entity.getHeldItem().isWeapon() ? "PUNCH" : null;
}

function isModifierEnabled(entity, modifier) {
    return modifier.name() == "fiskheroes:eternium_weakness" || !entity.hasStatusEffect("fiskheroes:eternium");
}
