var speedster_base = implement("fiskheroes:external/speedster_base");

function init(hero) {
    hero.setName("Tommy Maximoff");
    hero.setTier(1);

    hero.setChestplate("Chestpiece");
    hero.setLeggings("Pants");
    hero.setBoots("Boots");

    hero.addPowers("wv:super_speed");
    hero.addAttribute("PUNCH_DAMAGE", 2.0, 0);
    hero.addAttribute("WEAPON_DAMAGE", 0.5, 0);
    hero.addAttribute("BASE_SPEED_LEVELS", 3.0, 0);

    hero.addKeyBind("SUPER_SPEED", "key.superSpeed", 1);
    hero.addKeyBind("SLOW_MOTION", "key.slowMotion", 2);

    hero.setTickHandler((entity, manager) => {
        speedster_base.tick(entity, manager);
         
    hero.setTickHandler((entity, manager) => {
        manager.incrementData(entity, "wv:dyn/holoanimation", 20, 20, entity.is("DISPLAY") && !entity.as("DISPLAY").isStatic() && entity.as("DISPLAY").getDisplayType() === "HOLOGRAM");
    })

    });
    
    hero.setDefaultScale(0.8);
}