接口 SilkModelGenerator


@SilkApi public interface SilkModelGenerator

用于提供模组中常用但未提供更方便方法的模型生成方法

从以下版本开始:
0.1.0
  • 字段概要

    字段
    修饰符和类型
    字段
    说明
    static final net.minecraft.data.client.Model
     
  • 方法概要

    静态方法
    修饰符和类型
    方法
    说明
    static com.google.gson.JsonObject
    modelTransModeJson(float[] rotation, float[] translation, float[] scale)
     
    static void
    registerBlockItem(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.item.BlockItem blockItem)
     
    static void
    registerBowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Bow bow, float[] pullStage)
     
    static void
    registerCarpet(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block carpet, boolean isFlat)
     
    static void
    registerCrossbowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Crossbow crossbow, float[] pullStage)
     
    static void
    registerCustomDisplayBowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Bow bow, com.google.gson.JsonObject display, float[] pullStage)
     
    static void
    registerCustomDisplayCrossbowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Crossbow crossbow, com.google.gson.JsonObject display, float[] pullStage)
     
    static void
    registerId(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.util.Identifier id, net.minecraft.data.client.Model model)
     
    static void
    registerItemGroup(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.registry.RegistryKey<net.minecraft.item.ItemGroup> itemGroup)
    如果使用了 ItemGroupCreator.create(ModBasicData, String)创建了一个专门的物品组图标则使用此方法生成物品模型
    static void
    registerOverlayItemJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.item.Item item)
     
    static void
    registerTopSoil(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block soil)
     
    static void
    registerVines(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block plant, net.minecraft.block.Block plantStem, net.minecraft.data.client.BlockStateModelGenerator.TintType tintType)
     
  • 字段详细资料

    • TEMPLATE_SPAWN_EGG

      @SilkApi static final net.minecraft.data.client.Model TEMPLATE_SPAWN_EGG
  • 方法详细资料

    • modelTransModeJson

      @SilkApi static com.google.gson.JsonObject modelTransModeJson(float[] rotation, float[] translation, float[] scale)
    • registerId

      @SilkApi static void registerId(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.util.Identifier id, net.minecraft.data.client.Model model)
    • registerItemGroup

      @SilkApi static void registerItemGroup(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.registry.RegistryKey<net.minecraft.item.ItemGroup> itemGroup)
      如果使用了 ItemGroupCreator.create(ModBasicData, String)创建了一个专门的物品组图标则使用此方法生成物品模型
    • registerBlockItem

      @SilkApi static void registerBlockItem(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.item.BlockItem blockItem)
    • registerOverlayItemJson

      @SilkApi static void registerOverlayItemJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, net.minecraft.item.Item item)
    • registerBowJson

      @SilkApi static void registerBowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Bow bow, float[] pullStage)
    • registerCustomDisplayBowJson

      @SilkApi static void registerCustomDisplayBowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Bow bow, com.google.gson.JsonObject display, float[] pullStage)
    • registerCrossbowJson

      @SilkApi static void registerCrossbowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Crossbow crossbow, float[] pullStage)
    • registerCustomDisplayCrossbowJson

      @SilkApi static void registerCustomDisplayCrossbowJson(net.minecraft.data.client.ItemModelGenerator itemModelGenerator, Crossbow crossbow, com.google.gson.JsonObject display, float[] pullStage)
    • registerTopSoil

      @SilkApi static void registerTopSoil(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block soil)
    • registerCarpet

      @SilkApi static void registerCarpet(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block carpet, boolean isFlat)
    • registerVines

      @SilkApi static void registerVines(net.minecraft.data.client.BlockStateModelGenerator blockStateModelGenerator, net.minecraft.block.Block plant, net.minecraft.block.Block plantStem, net.minecraft.data.client.BlockStateModelGenerator.TintType tintType)