Entity Ticking Error on Server Join, Please help!
-
Recently Browsing
- No registered users viewing this page.
-
Posts
-
By Paint_Ninja · Posted
public ExampleMod(FMLJavaModLoadingContext context) { var modEventBus = context.getModEventBus(); } Refer to the javadocs and MDK for more pointers and examples. -
I recently updated my mod from 1.21 to 1.21.4. Didn't change anything on the data generation code (even though methods are now marked as deprecated) and had to change the block and item registration to explicitly add the id to avoid the "null pointer exception no id supplied" error The problem is that the block models work fine, as they did before, textures and all, but not the item ones. Is it because of this registration change? Did something in the datapack structure change on minecraft itself? Here is one of the registration lines im using as reference: RegistryObject<Item> CUSTOMITEM = ITEMS.register("item", () -> new RawMaterial(new Item.Properties().useItemDescriptionPrefix().setId(ResourceKey.create(Registries.ITEM, ResourceLocation.fromNamespaceAndPath(MOD_ID, "item")))))); and same for blocks: private static <T extends Block> RegistryObject<Item> registerBlockItem(String name, RegistryObject<T> block) { //T is the block type. It will register the block and the block item. return ModItems.ITEMS.register(name, () -> new BlockItem(block.get(), new Item.Properties().useBlockDescriptionPrefix().setId(ResourceKey.create(Registries.ITEM, ResourceLocation.fromNamespaceAndPath(MOD_ID, name))))); } RegistryObject<Block> CUSTOMORE = registerBlock("ore", () -> new CustomOre(Block.Properties.ofFullCopy(Blocks.STONE).setId(ResourceKey.create(Registries.BLOCK, ResourceLocation.fromNamespaceAndPath(MOD_ID,"ore")))))); Note that this made the translation keys i had pre 1.21.4 correctly show the translatable component, so im guessing that is okay, but just in case.
-
By TileEntity · Posted
Try the 1.4.0 build: https://modrinth.com/mod/cobblemon-gts/versions?g=1.21.1
-
-
Topics
-
Who's Online (See full list)
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.