Search in sources :

Example 1 with ModAPITransformer

use of net.minecraftforge.fml.common.asm.transformers.ModAPITransformer in project MinecraftForge by MinecraftForge.

the class ModClassLoader method addModAPITransformer.

public ModAPITransformer addModAPITransformer(ASMDataTable dataTable) {
    mainClassLoader.registerTransformer("net.minecraftforge.fml.common.asm.transformers.ModAPITransformer");
    List<IClassTransformer> transformers = mainClassLoader.getTransformers();
    ModAPITransformer modAPI = (ModAPITransformer) transformers.get(transformers.size() - 1);
    modAPI.initTable(dataTable);
    return modAPI;
}
Also used : ModAPITransformer(net.minecraftforge.fml.common.asm.transformers.ModAPITransformer) IClassTransformer(net.minecraft.launchwrapper.IClassTransformer)

Aggregations

IClassTransformer (net.minecraft.launchwrapper.IClassTransformer)1 ModAPITransformer (net.minecraftforge.fml.common.asm.transformers.ModAPITransformer)1