Class MegaModelTest

java.lang.Object
net.neoforged.neoforge.oldtest.client.model.MegaModelTest

public class MegaModelTest extends Object
Test mod that demos most Forge-provided model loaders in a single block + item, as well as in-JSON render states and the refactored immutable ModelData managed by the client level. The block can be found in the decoration tab.

Additionally, some fields in the JSON have deprecated names, so those MUST be updated in 1.20, or the model will break. They have all been annotated accordingly.

  • As a block: Composite loader, using 3 child element models, each with a different render type, some using vanilla's elements loader, and some Forge's
  • In the right hand: Fluid container with lava (emissive)
  • In the left hand: Multi-layer item with chainmail chestplate + emissive bow

Clicking on the upper half of the block will make the model move up by a bit, and clicking on the lower half will move it down.

  • Field Details

    • MOD_ID

      public static final String MOD_ID
      See Also:
    • BLOCKS

      private static final DeferredRegister.Blocks BLOCKS
    • ITEMS

      private static final DeferredRegister.Items ITEMS
    • BLOCK_ENTITIES

      private static final DeferredRegister<net.minecraft.world.level.block.entity.BlockEntityType<?>> BLOCK_ENTITIES
    • REG_NAME

      private static final String REG_NAME
      See Also:
    • TEST_BLOCK

      public static final DeferredBlock<net.minecraft.world.level.block.Block> TEST_BLOCK
    • TEST_BLOCK_ITEM

      public static final DeferredItem<net.minecraft.world.item.BlockItem> TEST_BLOCK_ITEM
    • TEST_BLOCK_ENTITY

      public static final DeferredHolder<net.minecraft.world.level.block.entity.BlockEntityType<?>,net.minecraft.world.level.block.entity.BlockEntityType<?>> TEST_BLOCK_ENTITY
  • Constructor Details

    • MegaModelTest

      public MegaModelTest(net.neoforged.bus.api.IEventBus modEventBus)
  • Method Details