IRunicArmor

Package: thaumcraft.api

Author: Azanor

Extends: —

Armor or bauble slot items that implement this interface can provide runic shielding. Recharging, hardening, etc. is handled internally by Thaumcraft.

Interface Definition

public interface IRunicArmor {
    /**
     * returns how much charge this item can provide. This is the base shielding value - any hardening is stored and calculated internally. 
     */
    public int getRunicCharge(ItemStack itemstack);
}

Methods

Method Signature Description
getRunicCharge ItemStack itemstack → int Returns the base runic charge this item provides. Hardening is stored and calculated internally by Thaumcraft.

Usage

Items implementing this interface grant the player runic shielding when equipped in armor or bauble slots. The returned value is the base shielding amount before Thaumcraft’s internal hardening calculations.

Example Implementation

public class MyRunicArmor extends ItemArmor implements IRunicArmor {
    
    @Override
    public int getRunicCharge(ItemStack itemstack) {
        return 50; // Provides 50 base runic charge
    }
}
  • ItemRunic: Built-in Thaumcraft item that implements this interface
  • Baubles API: Runic armor can be placed in bauble slots for passive shielding

Tags

#api #item-effect #armor #runic-shielding