Jump to content

Recommended Posts

Posted

So I had an error when i was trying to add a block to the game, Here is the error message:

[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.re.ObjectHolderRegistry/REGISTRIES]: Processing ObjectHolder annotations
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.re.ObjectHolderRegistry/REGISTRIES]: Found 2951 ObjectHolder annotations
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ModList/LOADING]: Dispatching synchronous event LifecycleEvent:LOAD_REGISTRIES
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid forge : RegistryEvent.Register<minecraft:block>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid forge : RegistryEvent.Register<minecraft:block>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid tutorialmod : RegistryEvent.Register<minecraft:block>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid tutorialmod : RegistryEvent.Register<minecraft:block>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.re.GameData/REGISTRIES]: Applying holder lookups: minecraft:block
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.re.GameData/REGISTRIES]: Holder lookups applied: minecraft:block
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ModList/LOADING]: Dispatching synchronous event LifecycleEvent:LOAD_REGISTRIES
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid forge : RegistryEvent.Register<minecraft:item>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid forge : RegistryEvent.Register<minecraft:item>
[m[36m[10:06:34] [Render thread/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid tutorialmod : RegistryEvent.Register<minecraft:item>
[m[1;31m[10:06:34] [Render thread/ERROR] [ne.mi.fm.ja.FMLModContainer/]: Exception caught during firing event: Can't use a null-name for the registry, object air.
    Index: 2
    Listeners:
        0: NORMAL
        1: ASM: class com.MrGreenyboy.TutorialMod.init.BlockInit registerBlock(Lnet/minecraftforge/event/RegistryEvent$Register;)V
        2: ASM: class com.MrGreenyboy.TutorialMod.init.BlockInit registerBlockItems(Lnet/minecraftforge/event/RegistryEvent$Register;)V
        3: ASM: class com.MrGreenyboy.TutorialMod.init.ItemInit registerItems(Lnet/minecraftforge/event/RegistryEvent$Register;)V
java.lang.NullPointerException: Can't use a null-name for the registry, object air.
    at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:864)
    at net.minecraftforge.registries.ForgeRegistry.add(ForgeRegistry.java:314)
    at net.minecraftforge.registries.ForgeRegistry.add(ForgeRegistry.java:308)
    at net.minecraftforge.registries.ForgeRegistry.register(ForgeRegistry.java:133)
    at com.MrGreenyboy.TutorialMod.init.BlockInit.registerBlockItems(BlockInit.java:27)
    at net.minecraftforge.eventbus.ASMEventHandler_15_BlockInit_registerBlockItems_Register.invoke(.dynamic)
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80)
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258)
    at net.minecraftforge.fml.javafmlmod.FMLModContainer.fireEvent(FMLModContainer.java:106)
    at java.util.function.Consumer.lambda$andThen$0(Unknown Source)
    at java.util.function.Consumer.lambda$andThen$0(Unknown Source)
    at net.minecraftforge.fml.ModContainer.transitionState(ModContainer.java:112)
    at net.minecraftforge.fml.ModList.lambda$dispatchSynchronousEvent$5(ModList.java:126)
    at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(Unknown Source)
    at java.util.stream.ReferencePipeline$Head.forEach(Unknown Source)
    at net.minecraftforge.fml.ModList.dispatchSynchronousEvent(ModList.java:126)
    at net.minecraftforge.fml.ModList.lambda$static$1(ModList.java:96)
    at net.minecraftforge.fml.LifecycleEventProvider.dispatch(LifecycleEventProvider.java:71)
    at net.minecraftforge.fml.ModLoader.dispatchAndHandleError(ModLoader.java:214)
    at net.minecraftforge.fml.ModLoader.lambda$gatherAndInitializeMods$25(ModLoader.java:206)
    at net.minecraftforge.registries.GameData.fireRegistryEvents(GameData.java:868)
    at net.minecraftforge.fml.ModLoader.gatherAndInitializeMods(ModLoader.java:206)
    at net.minecraftforge.fml.client.ClientModLoader.lambda$begin$2(ClientModLoader.java:93)
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:109)
    at net.minecraftforge.fml.client.ClientModLoader.begin(ClientModLoader.java:93)
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:425)
    at net.minecraft.client.main.Main.main(Main.java:149)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at net.minecraftforge.userdev.FMLUserdevClientLaunchProvider.lambda$launchService$0(FMLUserdevClientLaunchProvider.java:55)
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37)
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54)
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72)
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81)
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65)
    at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105)

[m[1;31m[10:06:34] [Render thread/ERROR] [ne.mi.fm.ja.FMLModContainer/LOADING]: Caught exception during event RegistryEvent.Register<minecraft:item> dispatch for modid tutorialmod
java.lang.NullPointerException: Can't use a null-name for the registry, object air.
    at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:864) ~[guava-21.0.jar:?] {}
    at net.minecraftforge.registries.ForgeRegistry.add(ForgeRegistry.java:314) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.registries.ForgeRegistry.add(ForgeRegistry.java:308) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.registries.ForgeRegistry.register(ForgeRegistry.java:133) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at com.MrGreenyboy.TutorialMod.init.BlockInit.registerBlockItems(BlockInit.java:27) ~[main/:?] {re:classloading,pl:object_holder_definalize:A}
    at net.minecraftforge.eventbus.ASMEventHandler_15_BlockInit_registerBlockItems_Register.invoke(.dynamic) ~[?:?] {}
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.fml.javafmlmod.FMLModContainer.fireEvent(FMLModContainer.java:106) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:32.0] {re:classloading}
    at java.util.function.Consumer.lambda$andThen$0(Unknown Source) ~[?:1.8.0_251] {}
    at java.util.function.Consumer.lambda$andThen$0(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecraftforge.fml.ModContainer.transitionState(ModContainer.java:112) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.ModList.lambda$dispatchSynchronousEvent$5(ModList.java:126) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(Unknown Source) ~[?:1.8.0_251] {}
    at java.util.stream.ReferencePipeline$Head.forEach(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecraftforge.fml.ModList.dispatchSynchronousEvent(ModList.java:126) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.ModList.lambda$static$1(ModList.java:96) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.LifecycleEventProvider.dispatch(LifecycleEventProvider.java:71) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.dispatchAndHandleError(ModLoader.java:214) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.lambda$gatherAndInitializeMods$25(ModLoader.java:206) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.registries.GameData.fireRegistryEvents(GameData.java:868) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.gatherAndInitializeMods(ModLoader.java:206) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$begin$2(ClientModLoader.java:93) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:109) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.begin(ClientModLoader.java:93) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:425) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(Main.java:149) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_251] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecraftforge.userdev.FMLUserdevClientLaunchProvider.lambda$launchService$0(FMLUserdevClientLaunchProvider.java:55) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.1.2.jar:?] {}
    at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105) [forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {}
[m[1;31m[10:06:34] [Render thread/FATAL] [ne.mi.fm.ModLoader/LOADING]: Failed to complete lifecycle event LOAD_REGISTRIES, 1 errors found
[m[1;31m[10:06:34] [Render thread/FATAL] [ne.mi.ev.EventBus/EVENTBUS]: EventBus 0 shutting down - future events will not be posted.
java.lang.Exception: stacktrace
    at net.minecraftforge.eventbus.EventBus.shutdown(EventBus.java:278) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:111) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.begin(ClientModLoader.java:93) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:425) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(Main.java:149) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {re:classloading,pl:runtimedistcleaner:A}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_251] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecraftforge.userdev.FMLUserdevClientLaunchProvider.lambda$launchService$0(FMLUserdevClientLaunchProvider.java:55) ~[forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.1.2.jar:?] {}
    at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105) [forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar:?] {}
[m[36m[10:06:35] [Render thread/DEBUG] [ne.mi.fm.cl.ClientModLoader/CORE]: Generating PackInfo named mod:forge for mod file C:\Users\dangr\.gradle\caches\forge_gradle\minecraft_user_repo\net\minecraftforge\forge\1.16.1-32.0.75_mapped_snapshot_20200514-1.16\forge-1.16.1-32.0.75_mapped_snapshot_20200514-1.16.jar
[m[36m[10:06:35] [Render thread/DEBUG] [ne.mi.fm.cl.ClientModLoader/CORE]: Generating PackInfo named mod:tutorialmod for mod file C:\Users\dangr\Documents\Youtube\mods\TutorialMod1.16.1(2)\bin\main
[m[32m[10:06:38] [Render thread/INFO] [mojang/NarratorWindows]: Narrator library for x64 successfully loaded
[m[32m[10:06:38] [Render thread/INFO] [minecraft/SimpleReloadableResourceManager]: Reloading ResourceManager: Default, Mod Resources
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.fm.co.ConfigTracker/CONFIG]: Loading configs type CLIENT
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.fm.co.ConfigFileTypeHandler/CONFIG]: Built TOML config for C:\Users\dangr\Documents\Youtube\mods\TutorialMod1.16.1(2)\run\config\forge-client.toml
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.fm.co.ConfigFileTypeHandler/CONFIG]: Loaded TOML config file C:\Users\dangr\Documents\Youtube\mods\TutorialMod1.16.1(2)\run\config\forge-client.toml
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.fm.co.ConfigFileTypeHandler/CONFIG]: Watching TOML config file C:\Users\dangr\Documents\Youtube\mods\TutorialMod1.16.1(2)\run\config\forge-client.toml for changes
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.co.ForgeConfig/FORGEMOD]: Loaded forge config file forge-client.toml
[m[36m[10:06:38] [Worker-Main-4/DEBUG] [ne.mi.fm.co.ConfigTracker/CONFIG]: Loading configs type COMMON
[m[1;31m[10:06:38] [Worker-Main-4/ERROR] [ne.mi.fm.ModLoader/LOADING]: Skipping lifecycle event SETUP, 1 errors found.
[m[1;31m[10:06:38] [Worker-Main-4/FATAL] [ne.mi.fm.ModLoader/LOADING]: Failed to complete lifecycle event SETUP, 1 errors found
[m[1;31m[10:06:38] [Worker-Main-4/FATAL] [ne.mi.ev.EventBus/EVENTBUS]: EventBus 0 shutting down - future events will not be posted.
java.lang.Exception: stacktrace
    at net.minecraftforge.eventbus.EventBus.shutdown(EventBus.java:278) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:111) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.startModLoading(ClientModLoader.java:119) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$onreload$3(ClientModLoader.java:101) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:109) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at java.util.concurrent.CompletableFuture$AsyncRun.run(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.CompletableFuture$AsyncRun.exec(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinTask.doExec(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinPool.runWorker(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source) [?:1.8.0_251] {}
[m[33m[10:06:43] [Worker-Main-6/WARN] [minecraft/ModelBakery]: Exception loading blockstate definition: 'tutorialmod:blockstates/example_block.json' missing model for variant: 'tutorialmod:example_block#'
[m[33m[10:06:43] [Worker-Main-6/WARN] [minecraft/ModelBakery]: Exception loading blockstate definition: 'tutorialmod:blockstates/example_block.json' in resourcepack: 'Mod Resources': java.io.EOFException: End of input at line 4 column 2 path $.variants.
[m[1;31m[10:06:46] [Worker-Main-6/ERROR] [ne.mi.fm.ModLoader/LOADING]: Skipping lifecycle event ENQUEUE_IMC, 1 errors found.
[m[1;31m[10:06:46] [Worker-Main-6/FATAL] [ne.mi.fm.ModLoader/LOADING]: Failed to complete lifecycle event ENQUEUE_IMC, 1 errors found
[m[1;31m[10:06:46] [Worker-Main-6/FATAL] [ne.mi.ev.EventBus/EVENTBUS]: EventBus 0 shutting down - future events will not be posted.
java.lang.Exception: stacktrace
    at net.minecraftforge.eventbus.EventBus.shutdown(EventBus.java:278) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$createRunnableWithCatch$5(ClientModLoader.java:111) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.finishModLoading(ClientModLoader.java:133) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraftforge.fml.client.ClientModLoader.lambda$onreload$4(ClientModLoader.java:103) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at java.util.concurrent.CompletableFuture.uniRun(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.CompletableFuture$UniRun.tryFire(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.CompletableFuture$Completion.exec(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinTask.doExec(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinPool.runWorker(Unknown Source) [?:1.8.0_251] {}
    at java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source) [?:1.8.0_251] {}
[m[36m[10:06:47] [Render thread/DEBUG] [ne.mi.fm.ForgeI18n/CORE]: Loading I18N data entries: 5136
[m[32m[10:06:47] [Render thread/INFO] [minecraft/SoundSystem]: OpenAL initialized.
[m[32m[10:06:47] [Render thread/INFO] [minecraft/SoundEngine]: Sound engine started
[m[32m[10:06:47] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 1024x512x4 minecraft:textures/atlas/blocks.png-atlas
[m[32m[10:06:47] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 256x128x4 minecraft:textures/atlas/signs.png-atlas
[m[32m[10:06:47] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 512x512x4 minecraft:textures/atlas/banner_patterns.png-atlas
[m[32m[10:06:47] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 512x512x4 minecraft:textures/atlas/shield_patterns.png-atlas
[m[32m[10:06:47] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 256x256x4 minecraft:textures/atlas/chest.png-atlas
[m[32m[10:06:48] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 512x256x4 minecraft:textures/atlas/beds.png-atlas
[m[32m[10:06:48] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 512x256x4 minecraft:textures/atlas/shulker_boxes.png-atlas
[m[32m[10:06:48] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 256x256x0 minecraft:textures/atlas/particles.png-atlas
[m[32m[10:06:48] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 256x256x0 minecraft:textures/atlas/paintings.png-atlas
[m[32m[10:06:48] [Render thread/INFO] [minecraft/AtlasTexture]: Created: 128x128x0 minecraft:textures/atlas/mob_effects.png-atlas
[m

Posted
4 minutes ago, diesieben07 said:

Show your code.

package com.MrGreenyboy.TutorialMod.init;

import net.minecraft.block.Block;
import net.minecraft.block.SoundType;
import net.minecraft.block.material.Material;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
import net.minecraftforge.event.RegistryEvent;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber.Bus;
import net.minecraftforge.registries.ObjectHolder;

@Mod.EventBusSubscriber(modid = "tutorialmod", bus = Bus.MOD)
@ObjectHolder("tutorialmod")
public class BlockInit {
    public static final Block example_block = null;
    
    @SubscribeEvent
    public static void registerBlock(final RegistryEvent.Register<Block> event) {
        event.getRegistry().register(new Block(Block.Properties.create(Material.IRON).sound(SoundType.SLIME)).setRegistryName("tutorialmod", "example_block"));
    }
    
    @SubscribeEvent
    public static void registerBlockItems(final RegistryEvent.Register<Item> event) {
        event.getRegistry().register(new BlockItem(example_block, new Item.Properties().maxStackSize(32).group(ItemGroup.BUILDING_BLOCKS)));
    }
}

 

Posted
4 minutes ago, diesieben07 said:

You did not set the registry name for your BlockItem.

I did this but setRegistryName is underlined in red, here is code:

 

package com.MrGreenyboy.TutorialMod.init;

import net.minecraft.block.Block;
import net.minecraft.block.SoundType;
import net.minecraft.block.material.Material;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
import net.minecraftforge.event.RegistryEvent;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber.Bus;
import net.minecraftforge.registries.ObjectHolder;

@Mod.EventBusSubscriber(modid = "tutorialmod", bus = Bus.MOD)
@ObjectHolder("tutorialmod")
public class BlockInit {
    public static final Block example_block = null;
    
    @SubscribeEvent
    public static void registerBlock(final RegistryEvent.Register<Block> event) {
        event.getRegistry().register(new Block(Block.Properties.create(Material.IRON).sound(SoundType.SLIME)).setRegistryName("tutorialmod", "example_block"));
    }
    
    @SubscribeEvent
    public static void registerBlockItems(final RegistryEvent.Register<Item> event) {
        event.getRegistry().register(new BlockItem(example_block, new Item.Properties().maxStackSize(32).group(ItemGroup.BUILDING_BLOCKS).setRegistryName("example_block")));
    }
}

 

Posted
3 minutes ago, MrGreenyboy said:

I did this but setRegistryName is underlined in red, here is code:

 

package com.MrGreenyboy.TutorialMod.init;

import net.minecraft.block.Block;
import net.minecraft.block.SoundType;
import net.minecraft.block.material.Material;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
import net.minecraftforge.event.RegistryEvent;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber.Bus;
import net.minecraftforge.registries.ObjectHolder;

@Mod.EventBusSubscriber(modid = "tutorialmod", bus = Bus.MOD)
@ObjectHolder("tutorialmod")
public class BlockInit {
    public static final Block example_block = null;
    
    @SubscribeEvent
    public static void registerBlock(final RegistryEvent.Register<Block> event) {
        event.getRegistry().register(new Block(Block.Properties.create(Material.IRON).sound(SoundType.SLIME)).setRegistryName("tutorialmod", "example_block"));
    }
    
    @SubscribeEvent
    public static void registerBlockItems(final RegistryEvent.Register<Item> event) {
        event.getRegistry().register(new BlockItem(example_block, new Item.Properties().maxStackSize(32).group(ItemGroup.BUILDING_BLOCKS).setRegistryName("example_block")));
    }
}

 

I moved setRegistryName and it doesn't appear to have errors i am going to try and run the game now

 

Posted
6 minutes ago, MrGreenyboy said:

I moved setRegistryName and it doesn't appear to have errors i am going to try and run the game now

 

Now when i enter the game it doesn't have a block model when i place it downspacer.png

Posted (edited)
9 minutes ago, MrGreenyboy said:

Now when i enter the game it doesn't have a block model when i place it down

Show your block's blockstate and model jsons file please. Anyway if you are using 1.16.1 registering things with DeferredRegister is (in my opinion) far simpler than using registry events, and probably less prone to errors like the one you encountered.

Edited by Beethoven92

Check out the port of the BetterEnd fabric mod (WIP): https://www.curseforge.com/minecraft/mc-mods/betterend-forge-port

Posted
2 minutes ago, Beethoven92 said:

Show your block's blockstate and model jsons file please

Here is the blockstates file:

{
    "variants":{
        "":{ "model": "tutorialmod:block/example_block"
}

 

Here is the models blocks file:

{
    "parent": "block/cube_all",
    "textures": {
        "all": "tutorialmod:blocks/example_block"
    }
}

 

Posted
2 minutes ago, poopoodice said:

one for the "variants" as well, consider download a json validator in your ide

Ok I will go and do that. Also I added the second bracket to the blockstate json and i still didn't see any texture. I found an error message but then the console pushed it so far back i can't see it

Posted
Just now, Beethoven92 said:

Post again your blockstate json

 

{
    "variants":{
        "":{ "model": "tutorialmod:block/example_block" }
}

 

also should it be blockstates or blockstate

Posted (edited)

It is still missing a closing bracket, you see? You are now closing the "" block correctly, but still the "variants" block misses its closing bracket. Suggestion, just count your brackets, there should never be an odd number of them.

 

Also the package name needs to be blockstates

Edited by Beethoven92

Check out the port of the BetterEnd fabric mod (WIP): https://www.curseforge.com/minecraft/mc-mods/betterend-forge-port

Posted

Here is an error i found

 

[m[32m[11:19:33] [Forge Version Check/INFO] [ne.mi.fm.VersionChecker/]: [forge] Found status: BETA_OUTDATED Current: 32.0.75 Target: 32.0.97
[m[32m[11:19:33] [Forge Version Check/INFO] [ne.mi.fm.VersionChecker/]: [tutorialmod] Starting version check at http://myurl.me/
[m[33m[11:19:33] [Forge Version Check/WARN] [ne.mi.fm.VersionChecker/]: Failed to process update information
java.io.IOException: Server returned HTTP response code: 400 for URL: http://myurl.me/
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:1.8.0_251] {}
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) ~[?:1.8.0_251] {}
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) ~[?:1.8.0_251] {}
    at java.lang.reflect.Constructor.newInstance(Unknown Source) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection$10.run(Unknown Source) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection$10.run(Unknown Source) ~[?:1.8.0_251] {}
    at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection.getChainedException(Unknown Source) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecraftforge.fml.VersionChecker$1.openUrlStream(VersionChecker.java:189) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.VersionChecker$1.process(VersionChecker.java:206) ~[?:?] {re:classloading}
    at java.lang.Iterable.forEach(Unknown Source) [?:1.8.0_251] {}
    at net.minecraftforge.fml.VersionChecker$1.run(VersionChecker.java:157) [?:?] {re:classloading}
Caused by: java.io.IOException: Server returned HTTP response code: 400 for URL: http://myurl.me/
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source) ~[?:1.8.0_251] {}
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source) ~[?:1.8.0_251] {}
    at java.net.HttpURLConnection.getResponseCode(Unknown Source) ~[?:1.8.0_251] {}
    at net.minecr

Posted (edited)
7 minutes ago, Beethoven92 said:

It is still missing a closing bracket, you see? You are now closing the "" block correctly, but still the "variants" block misses its closing bracket. Suggestion, just count your brackets, there should never be an odd number of them.

 

Also the package name needs to be blockstates

I edited the blockstates json and put this:

{
  "variants": {
    "": {
      "model": "tutorialmod:block/example_block"
    }
  }
}

Edited by MrGreenyboy
Posted
2 minutes ago, MrGreenyboy said:

I edited the blockstates json and put this:

{
  "variants": {
    "": {
      "model": "tutorialmod:block/example_block"
    }
  }
}

It Works I now have a block model thanks for all who helped with the load_registries error and for all who helped with the texture error

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.