Abilities

Attach active and passive abilities to weapons. Planned for v0.2.0; hooks are already present in base classes.

Passive abilities

Active abilities

Hooks

public class Stormcaller extends ArmariaMeleeWeapon {
    public Stormcaller(Properties props) {
        super(props);
        addPassiveAbility(Abilities.LIFESTEAL, 0.15f);
        addAbility(Abilities.CHAIN_LIGHTNING, 4, 5.0f, 0.8f);
        setTexture(Texture2D.of("armaria:item/stormcaller"));
    }

    @Override
    public void postHurtEnemy(ItemStack stack, LivingEntity target, LivingEntity attacker) {
        VFXPresets.stormChain(attacker, InteractionHand.MAIN_HAND);
    }
}

Cooldowns and mana

Use the existing charge system as a mana proxy, and track cooldowns in ticks inside your weapon class.

Status The ability registry and helper methods are planned for v0.2.0. The onChargeFull and postHurtEnemy hooks already exist and can be used today.