Class ItemModelGeneratorMixin

java.lang.Object
io.github.vampirestudios.vampirelib.mixins.ItemModelGeneratorMixin
All Implemented Interfaces:
FabricItemModelGenerator

public class ItemModelGeneratorMixin extends Object implements FabricItemModelGenerator
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    BiConsumer<net.minecraft.resources.ResourceLocation,Supplier<com.google.gson.JsonElement>>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    register(net.minecraft.world.item.Item item, String suffix, net.minecraft.data.models.model.ModelTemplate model, net.minecraft.data.models.model.TextureMapping textureMap)
    Generates an item's model based on the given model template and corresponding texture mapping.
    void
    register(net.minecraft.world.item.Item item, net.minecraft.data.models.model.ModelTemplate model, net.minecraft.data.models.model.TextureMapping textureMap)
    Generates an item's model based on the given model template and corresponding texture mapping.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface io.github.vampirestudios.vampirelib.api.datagen.FabricItemModelGenerator

    build, build
  • Field Details

    • output

      public BiConsumer<net.minecraft.resources.ResourceLocation,Supplier<com.google.gson.JsonElement>> output
  • Constructor Details

    • ItemModelGeneratorMixin

      public ItemModelGeneratorMixin()
  • Method Details

    • register

      public void register(net.minecraft.world.item.Item item, net.minecraft.data.models.model.ModelTemplate model, net.minecraft.data.models.model.TextureMapping textureMap)
      Description copied from interface: FabricItemModelGenerator
      Generates an item's model based on the given model template and corresponding texture mapping. Both the model and mapping must be made with the same set of texture keys.
      Specified by:
      register in interface FabricItemModelGenerator
      Parameters:
      item - The item to generate this model for.
      model - The desired template to generate this model out of.
      textureMap - The desired texture mapping for this model.
    • register

      public void register(net.minecraft.world.item.Item item, String suffix, net.minecraft.data.models.model.ModelTemplate model, net.minecraft.data.models.model.TextureMapping textureMap)
      Description copied from interface: FabricItemModelGenerator
      Generates an item's model based on the given model template and corresponding texture mapping. Both the model and mapping must be made with the same set of texture keys.
      Specified by:
      register in interface FabricItemModelGenerator
      Parameters:
      item - The item to generate this model for.
      suffix - An optional suffix for the generated model's file name.
      model - The desired template to generate this model out of.
      textureMap - The desired texture mapping for this model.