Jump to content

The game crashed whilst initializing game Error: java.lang.NullPointerException: Registry Object not present


Recommended Posts

Posted
Please help with such a mistake.
The game crashed whilst initializing game
Error: java.lang.NullPointerException: Registry Object not present

Minecraft version 1.15.1
Mods that are installed:
XaerosWorldMap_1.5.3_Forge_1.15.1
unstabletools_1.15.1_4.0
UndergroundMaterials_1.15.1_1.3.1
titanium-1.15.1-2.3.4
SimpleStorageNetwork_1.15.1_0.2.0
Mekanism_1.15.1_9.9.3.394
industrial-foregoing-1.15.1-2.2.0
FallingTree_1.15.1_2.0.213

Posted
2 hours ago, diesieben07 said:

Разместите полный журнал.

---- Minecraft Crash Report ----
// There are four lights!

Time: 07.02.20 18:28
Description: Initializing game

java.lang.NullPointerException: Registry Object not present
    at java.util.Objects.requireNonNull(Objects.java:228) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.RegistryObject.get(RegistryObject.java:91) ~[?:?] {re:classloading}
    at mekanism.common.registration.DoubleWrappedRegistryObject.getPrimary(DoubleWrappedRegistryObject.java:23) ~[?:?] {re:classloading}
    at mekanism.common.registration.impl.BlockRegistryObject.getBlock(BlockRegistryObject.java:19) ~[?:?] {re:classloading}
    at mekanism.client.ClientRegistrationUtil.registerBlockColorHandler(ClientRegistrationUtil.java:78) ~[?:?] {re:classloading}
    at mekanism.client.ClientRegistration.registerItemColorHandlers(ClientRegistration.java:401) ~[?:?] {re:classloading}
    at net.minecraftforge.eventbus.ASMEventHandler_32_ClientRegistration_registerItemColorHandlers_Item.invoke(.dynamic) ~[?:?] {}
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.fml.javafmlmod.FMLModContainer.acceptEvent(FMLModContainer.java:168) ~[?:30.0] {re:classloading}
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader$$Lambda$2350/1013051356.accept(Unknown Source) ~[?:?] {}
    at java.util.HashMap.forEach(HashMap.java:1280) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:209) ~[?:?] {re:classloading}
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:420) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(SourceFile:164) [?:?] {re:classloading}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56) [forge-1.15.1-30.0.51.jar:30.0] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$406/389779746.call(Unknown Source) [forge-1.15.1-30.0.51.jar:30.0] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.0.0-milestone.4.jar:?] {}


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Thread: Render thread
Stacktrace:
    at java.util.Objects.requireNonNull(Objects.java:228)
    at net.minecraftforge.fml.RegistryObject.get(RegistryObject.java:91)
    at mekanism.common.registration.DoubleWrappedRegistryObject.getPrimary(DoubleWrappedRegistryObject.java:23)
    at mekanism.common.registration.impl.BlockRegistryObject.getBlock(BlockRegistryObject.java:19)
    at mekanism.client.ClientRegistrationUtil.registerBlockColorHandler(ClientRegistrationUtil.java:78)
    at mekanism.client.ClientRegistration.registerItemColorHandlers(ClientRegistration.java:401)
    at net.minecraftforge.eventbus.ASMEventHandler_32_ClientRegistration_registerItemColorHandlers_Item.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.acceptEvent(FMLModContainer.java:168)
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243)
    at net.minecraftforge.fml.ModLoader$$Lambda$2350/1013051356.accept(Unknown Source)
    at java.util.HashMap.forEach(HashMap.java:1280)
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217)
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243)
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:209)
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84)
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:420)

-- Initialization --
Details:
Stacktrace:
    at net.minecraft.client.main.Main.main(SourceFile:164)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$406/389779746.call(Unknown Source)
    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)

-- System Details --
Details:
    Minecraft Version: 1.15.1
    Minecraft Version ID: 1.15.1
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 1.8.0_51, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 1678001888 bytes (1600 MB) / 2147483648 bytes (2048 MB) up to 2147483648 bytes (2048 MB)
    CPUs: 4
    JVM Flags: 9 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xss1M -Xmx2G -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
    ModLauncher: 5.0.0-milestone.4+67+b1a340b
    ModLauncher launch target: fmlclient
    ModLauncher naming: srg
    ModLauncher services: 
        /eventbus-2.0.0-milestone.1-service.jar eventbus PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar object_holder_definalize PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar runtime_enum_extender PLUGINSERVICE 
        /accesstransformers-2.0.0-milestone.1-shadowed.jar accesstransformer PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar capability_inject_definalize PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar runtimedistcleaner PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar fml TRANSFORMATIONSERVICE 
    FML: 30.0
    Forge: net.minecraftforge:30.0.51
    FML Language Providers: 
        [email protected]
        minecraft@1
    Mod List: 
        forge-1.15.1-30.0.51-client.jar Minecraft {[email protected] CREATE_REGISTRIES}
        SimpleStorageNetwork_1.15.1_0.2.0.jar Simple Storage Network {[email protected] CREATE_REGISTRIES}
        industrial-foregoing-1.15.1-2.2.0.jar Industrial Foregoing {[email protected] ERROR}
        FallingTree_1.15.1_2.0.213.jar Falling Tree {[email protected]+13 CREATE_REGISTRIES}
        Mekanism_1.15.1_9.9.3.394.jar Mekanism {[email protected] ERROR}
        forge-1.15.1-30.0.51-universal.jar Forge {[email protected] CREATE_REGISTRIES}
        titanium-1.15.1-2.3.4.jar Titanium {[email protected] ERROR}
        UndergroundMaterials_1.15.1_1.3.1.jar Underground Materials {[email protected] CREATE_REGISTRIES}
        SolarGeneration_1.15.1_1.1.0.jar Solar Generation {[email protected] CREATE_REGISTRIES}
        unstabletools_1.15.1_4.0.jar Unstable Tools {[email protected] CREATE_REGISTRIES}
        XaerosWorldMap_1.5.3_Forge_1.15.1.jar Xaero's World Map {[email protected] CREATE_REGISTRIES}
    Launched Version: 1.15.1-forge-30.0.51
    Backend library: LWJGL version 3.2.2 build 10
    Backend API: GeForce GT 520M/PCIe/SSE2 GL version 4.6.0 NVIDIA 391.35, NVIDIA Corporation
    GL Caps: Using framebuffer using OpenGL 3.0
    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'forge'
    Type: Client (map_client.txt)
    CPU: 4x Intel(R) Core(TM) i3 CPU M 370 @ 2.40GHz

Posted
57 minutes ago, diesieben07 said:

Проблема с меканизмом.

Удостоверьтесь, что это актуально, иначе говорите с автором.

Thank

Posted (edited)

It didn’t help, here are the new logs
 

---- Minecraft Crash Report ----
// Hey, that tickles! Hehehe!

Time: 07.02.20 20:19
Description: Initializing game

java.lang.NullPointerException: Initializing game
    at net.minecraft.client.renderer.RenderTypeLookup.setRenderLayer(RenderTypeLookup.java:317) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.renderer.RenderTypeLookup.setRenderLayer(RenderTypeLookup.java:313) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at com.tfar.unstabletools.Client.colors(Client.java:16) ~[?:4.0] {re:classloading}
    at net.minecraftforge.eventbus.ASMEventHandler_18_Client_colors_Item.invoke(.dynamic) ~[?:?] {}
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.fml.javafmlmod.FMLModContainer.acceptEvent(FMLModContainer.java:168) ~[?:30.0] {re:classloading}
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader$$Lambda$2293/623898104.accept(Unknown Source) ~[?:?] {}
    at java.util.HashMap.forEach(HashMap.java:1280) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:209) ~[?:?] {re:classloading}
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:420) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(SourceFile:164) [?:?] {re:classloading}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56) [forge-1.15.1-30.0.51.jar:30.0] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$406/1460126155.call(Unknown Source) [forge-1.15.1-30.0.51.jar:30.0] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.0.0-milestone.4.jar:?] {}


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Thread: Render thread
Stacktrace:
    at net.minecraft.client.renderer.RenderTypeLookup.setRenderLayer(RenderTypeLookup.java:317)
    at net.minecraft.client.renderer.RenderTypeLookup.setRenderLayer(RenderTypeLookup.java:313)
    at com.tfar.unstabletools.Client.colors(Client.java:16)
    at net.minecraftforge.eventbus.ASMEventHandler_18_Client_colors_Item.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.acceptEvent(FMLModContainer.java:168)
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243)
    at net.minecraftforge.fml.ModLoader$$Lambda$2293/623898104.accept(Unknown Source)
    at java.util.HashMap.forEach(HashMap.java:1280)
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217)
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243)
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:209)
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84)
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:420)

-- Initialization --
Details:
Stacktrace:
    at net.minecraft.client.main.Main.main(SourceFile:164)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$406/1460126155.call(Unknown Source)
    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)

-- System Details --
Details:
    Minecraft Version: 1.15.1
    Minecraft Version ID: 1.15.1
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 1.8.0_51, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 1466904592 bytes (1398 MB) / 2147483648 bytes (2048 MB) up to 2147483648 bytes (2048 MB)
    CPUs: 4
    JVM Flags: 9 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xss1M -Xmx2G -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
    ModLauncher: 5.0.0-milestone.4+67+b1a340b
    ModLauncher launch target: fmlclient
    ModLauncher naming: srg
    ModLauncher services: 
        /eventbus-2.0.0-milestone.1-service.jar eventbus PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar object_holder_definalize PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar runtime_enum_extender PLUGINSERVICE 
        /accesstransformers-2.0.0-milestone.1-shadowed.jar accesstransformer PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar capability_inject_definalize PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar runtimedistcleaner PLUGINSERVICE 
        /forge-1.15.1-30.0.51.jar fml TRANSFORMATIONSERVICE 
    FML: 30.0
    Forge: net.minecraftforge:30.0.51
    FML Language Providers: 
        [email protected]
        minecraft@1
    Mod List: 
        forge-1.15.1-30.0.51-client.jar Minecraft {[email protected] CREATE_REGISTRIES}
        SimpleStorageNetwork_1.15.1_0.2.0.jar Simple Storage Network {[email protected] CREATE_REGISTRIES}
        industrial-foregoing-1.15.1-2.2.0.jar Industrial Foregoing {[email protected] ERROR}
        FallingTree_1.15.1_2.0.213.jar Falling Tree {[email protected]+13 CREATE_REGISTRIES}
        forge-1.15.1-30.0.51-universal.jar Forge {[email protected] CREATE_REGISTRIES}
        titanium-1.15.1-2.3.4.jar Titanium {[email protected] ERROR}
        UndergroundMaterials_1.15.1_1.3.1.jar Underground Materials {[email protected] CREATE_REGISTRIES}
        SolarGeneration_1.15.1_1.1.0.jar Solar Generation {[email protected] CREATE_REGISTRIES}
        unstabletools_1.15.1_4.0.jar Unstable Tools {[email protected] CREATE_REGISTRIES}
        XaerosWorldMap_1.5.3_Forge_1.15.1.jar Xaero's World Map {[email protected] CREATE_REGISTRIES}
    Launched Version: 1.15.1-forge-30.0.51
    Backend library: LWJGL version 3.2.2 build 10
    Backend API: GeForce GT 520M/PCIe/SSE2 GL version 4.6.0 NVIDIA 391.35, NVIDIA Corporation
    GL Caps: Using framebuffer using OpenGL 3.0
    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'forge'
    Type: Client (map_client.txt)
    CPU: 4x Intel(R) Core(TM) i3 CPU M 370 @ 2.40GHz

 

Edited by KaiNrav
  • 4 weeks later...
Posted

---- Minecraft Crash Report ----
// Hey, that tickles! Hehehe!

Time: 2/29/20 11:37 AM
Description: Initializing game

java.lang.NullPointerException: Registry Object not present
    at java.util.Objects.requireNonNull(Objects.java:228) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.RegistryObject.get(RegistryObject.java:91) ~[?:?] {re:classloading}
    at mekanism.common.registration.DoubleWrappedRegistryObject.getPrimary(DoubleWrappedRegistryObject.java:23) ~[?:?] {re:classloading}
    at mekanism.common.registration.impl.BlockRegistryObject.getBlock(BlockRegistryObject.java:19) ~[?:?] {re:classloading}
    at mekanism.client.ClientRegistrationUtil.registerBlockColorHandler(ClientRegistrationUtil.java:108) ~[?:?] {re:classloading}
    at mekanism.client.ClientRegistration.registerItemColorHandlers(ClientRegistration.java:397) ~[?:?] {re:classloading}
    at net.minecraftforge.eventbus.ASMEventHandler_275_ClientRegistration_registerItemColorHandlers_Item.invoke(.dynamic) ~[?:?] {}
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258) ~[eventbus-2.0.0-milestone.1-service.jar:?] {}
    at net.minecraftforge.fml.javafmlmod.FMLModContainer.acceptEvent(FMLModContainer.java:168) ~[?:31.1] {re:classloading}
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader$$Lambda$3464/452691527.accept(Unknown Source) ~[?:?] {}
    at java.util.HashMap.forEach(HashMap.java:1280) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217) ~[?:?] {re:classloading}
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243) ~[?:?] {re:classloading}
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:203) ~[?:?] {re:classloading}
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:421) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(SourceFile:166) [?:?] {re:classloading}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56) [forge-1.15.2-31.1.18.jar:31.1] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$421/954936400.call(Unknown Source) [forge-1.15.2-31.1.18.jar:31.1] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.0.0-milestone.4.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.0.0-milestone.4.jar:?] {}


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Thread: Render thread
Stacktrace:
    at java.util.Objects.requireNonNull(Objects.java:228)
    at net.minecraftforge.fml.RegistryObject.get(RegistryObject.java:91)
    at mekanism.common.registration.DoubleWrappedRegistryObject.getPrimary(DoubleWrappedRegistryObject.java:23)
    at mekanism.common.registration.impl.BlockRegistryObject.getBlock(BlockRegistryObject.java:19)
    at mekanism.client.ClientRegistrationUtil.registerBlockColorHandler(ClientRegistrationUtil.java:108)
    at mekanism.client.ClientRegistration.registerItemColorHandlers(ClientRegistration.java:397)
    at net.minecraftforge.eventbus.ASMEventHandler_275_ClientRegistration_registerItemColorHandlers_Item.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.acceptEvent(FMLModContainer.java:168)
    at net.minecraftforge.fml.ModLoader.lambda$postEvent$30(ModLoader.java:243)
    at net.minecraftforge.fml.ModLoader$$Lambda$3464/452691527.accept(Unknown Source)
    at java.util.HashMap.forEach(HashMap.java:1280)
    at net.minecraftforge.fml.ModList.forEachModContainer(ModList.java:217)
    at net.minecraftforge.fml.ModLoader.postEvent(ModLoader.java:243)
    at net.minecraftforge.client.ForgeHooksClient.onItemColorsInit(ForgeHooksClient.java:203)
    at net.minecraft.client.renderer.color.ItemColors.func_186729_a(ItemColors.java:84)
    at net.minecraft.client.Minecraft.<init>(Minecraft.java:421)

-- Initialization --
Details:
Stacktrace:
    at net.minecraft.client.main.Main.main(SourceFile:166)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$421/954936400.call(Unknown Source)
    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)

-- System Details --
Details:
    Minecraft Version: 1.15.2
    Minecraft Version ID: 1.15.2
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 1.8.0_51, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 1485101392 bytes (1416 MB) / 2147483648 bytes (2048 MB) up to 2147483648 bytes (2048 MB)
    CPUs: 4
    JVM Flags: 9 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xss1M -Xmx2G -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
    ModLauncher: 5.0.0-milestone.4+67+b1a340b
    ModLauncher launch target: fmlclient
    ModLauncher naming: srg
    ModLauncher services: 
        /eventbus-2.0.0-milestone.1-service.jar eventbus PLUGINSERVICE 
        /forge-1.15.2-31.1.18.jar object_holder_definalize PLUGINSERVICE 
        /forge-1.15.2-31.1.18.jar runtime_enum_extender PLUGINSERVICE 
        /accesstransformers-2.0.3-shadowed.jar accesstransformer PLUGINSERVICE 
        /forge-1.15.2-31.1.18.jar capability_inject_definalize PLUGINSERVICE 
        /forge-1.15.2-31.1.18.jar runtimedistcleaner PLUGINSERVICE 
        /forge-1.15.2-31.1.18.jar fml TRANSFORMATIONSERVICE 
    FML: 31.1
    Forge: net.minecraftforge:31.1.18
    FML Language Providers: 
        [email protected]
        minecraft@1
    Mod List: 
        Colbbs-Donut-Mod-1.15.2-1.0.0.jar Colbb's Donut Mod {[email protected] CREATE_REGISTRIES}
        torchslabmod-1.15.1_v1.5.jar Torch Slab Mod {[email protected] CREATE_REGISTRIES}
        mining-helmet-1.15.2-1.0.6.jar Mining Helmet {[email protected] CREATE_REGISTRIES}
        SBM-BoneTorch-1.15.2-0.0.1.jar [SBM] BoneTorch {[email protected] CREATE_REGISTRIES}
        Realistic+Ulities+4.1.1.jar Realistic Ulities {[email protected] CREATE_REGISTRIES}
        goblintraders-1.2.0-1.15.2.jar Goblin Traders {[email protected] CREATE_REGISTRIES}
        Mekanism-1.15.2-9.9.11.403.jar Mekanism {[email protected] CREATE_REGISTRIES}
        caelus-FORGE-1.15.2-2.0-beta1.jar Caelus API {[email protected] CREATE_REGISTRIES}
        colytra-FORGE-1.15.2-3.0.jar Colytra {[email protected] CREATE_REGISTRIES}
        rsgauges-1.15.2-1.2.1.jar Gauges and Switches {[email protected] CREATE_REGISTRIES}
        Waystones_1.15.2-6.0.0.jar Waystones {[email protected] CREATE_REGISTRIES}
        good-nights-sleep-1.15.2-1.0.2.jar Good Night's Sleep {[email protected] CREATE_REGISTRIES}
        additionalbars-1.2.1.jar Additional Bars {[email protected] CREATE_REGISTRIES}
        SereneSeasons-1.15.2-3.0.0.66-universal.jar Serene Seasons {[email protected] CREATE_REGISTRIES}
        decorative_blocks_5.jar Decorative Blocks {[email protected] CREATE_REGISTRIES}
        DungeonCrawl-1.15.2-1.6.3.jar Dungeon Crawl {[email protected] CREATE_REGISTRIES}
        reciperandomizer-1.0.jar Example Mod {[email protected] CREATE_REGISTRIES}
        FarmingForBlockheads_1.15.2-6.1.0.jar Farming for Blockheads {[email protected] CREATE_REGISTRIES}
        UnforgivingVoid-1.15.2-1.0.4.jar Unforgiving Void {[email protected] CREATE_REGISTRIES}
        PickUpNotifier-v1.1.2-1.15.2.jar Pick Up Notifier {[email protected] CREATE_REGISTRIES}
        immersive-portals-0.4(for+mc+1.15+with+forge).jar Immersive Portals {[email protected] CREATE_REGISTRIES}
        campfiretorches-1.15.2-1.0.2.jar Campfire Torches {[email protected] CREATE_REGISTRIES}
        forge-1.15.2-31.1.18-universal.jar Forge {[email protected] CREATE_REGISTRIES}
        refinedstorage-1.8.1.jar Refined Storage {[email protected] CREATE_REGISTRIES}
        forge-1.15.2-31.1.18-client.jar Minecraft {[email protected] CREATE_REGISTRIES}
        industrial-foregoing-1.15.2-2.2.1-f27c515.jar Industrial Foregoing {[email protected] CREATE_REGISTRIES}
        titanium-1.15.2-2.3.6.jar Titanium {[email protected] CREATE_REGISTRIES}
        SilentLib-1.15.2-4.6.0+48.jar Silent Lib {[email protected]+48 CREATE_REGISTRIES}
        BiomesOPlenty-1.15.2-10.0.0.345-universal (1).jar Biomes O' Plenty {[email protected] CREATE_REGISTRIES}
        valhelsia_structures-15.0.2.jar Valhelsia Structures {[email protected] CREATE_REGISTRIES}
        ironfurnaces-1.15.2-2.0.1.jar Iron Furnaces {[email protected] CREATE_REGISTRIES}
        SilentGear-1.15.2-1.5.2+77.jar Silent Gear {[email protected]+77 CREATE_REGISTRIES}
        simplefarming-1.15.2-1.2.7.jar Simple Farming {[email protected] CREATE_REGISTRIES}
        ceilingtorch-1.15.2-v1.5.jar Ceiling Torch {[email protected] CREATE_REGISTRIES}
        astikorcarts-1.0.1-1.15.2.jar AstikorCarts {[email protected] CREATE_REGISTRIES}
        simplybackpacks-1.15.2-1.3.0.jar Simply Backpacks {[email protected] CREATE_REGISTRIES}
        dimdungeons-1.04-forge-1.15.2.jar Dimensional Dungeons {[email protected] CREATE_REGISTRIES}
        randomenchants-3.1.0.jar Random Enchants {[email protected] ERROR}
        enchantedwolves-1.4.2.jar Enchanted Wolves {[email protected] CREATE_REGISTRIES}
        DoubleSlabs-1.15-2.0.1.jar Double Slabs {[email protected] CREATE_REGISTRIES}
        backpacked-1.4.1-mc1.15.2.jar Backpacked {[email protected] CREATE_REGISTRIES}
        lostcities-1.15-3.0.0-alpha.jar LostCities {[email protected] CREATE_REGISTRIES}
        tombstone-4.2.4-1.15.2 (1).jar Corail Tombstone {[email protected] CREATE_REGISTRIES}
        obfuscate-0.3.4-1.15.2.jar Obfuscate {[email protected] CREATE_REGISTRIES}
        vehicle-0.42.5-mc1.15.2.jar MrCrayfish's Vehicle Mod {[email protected] CREATE_REGISTRIES}
        structurize-0.10.269-ALPHA.jar Structurize {[email protected] CREATE_REGISTRIES}
        worldedit-forge-mc1.15.2-7.1.0.jar WorldEdit {[email protected];48cc31c CREATE_REGISTRIES}
        Survivalist-1.15.2-3.0.1 (1).jar Survivalist {[email protected] CREATE_REGISTRIES}
        minecolonies-0.10.730-ALPHA-universal.jar Minecolonies {[email protected] CREATE_REGISTRIES}
        almostalltheores-2.0.2.0.jar Almost All the Ores {[email protected] CREATE_REGISTRIES}
        Aquaculture-1.15.2-2.0.9.jar Aquaculture 2 {[email protected] CREATE_REGISTRIES}
        SilentGems-1.15.2-3.5.1+84.jar Silent's Gems 3 {[email protected]+84 CREATE_REGISTRIES}
        XL-Food-Mod-1.15.2-2.2.2.jar XL Food Mod {[email protected] CREATE_REGISTRIES}
        ElementaryOres-1.15.2-1.0.0.jar Elementary Ores {[email protected] CREATE_REGISTRIES}
        CosmeticArmorReworked-1.15.2-v1a.jar CosmeticArmorReworked {[email protected] CREATE_REGISTRIES}
        Cyclic-1.15.2-0.1.10.jar Cyclic {[email protected] CREATE_REGISTRIES}
        BetterAdvancements-1.15.2-0.1.0.96.jar Better Advancements {[email protected] CREATE_REGISTRIES}
    Launched Version: 1.15.2-forge-31.1.18
    Backend library: LWJGL version 3.2.2 build 10
    Backend API: Intel(R) HD Graphics 405 GL version 4.4.0 - Build 20.19.15.4509, Intel
    GL Caps: Using framebuffer using OpenGL 3.0
    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'forge'
    Type: Client (map_client.txt)
    CPU: 4x Intel(R) Pentium(R) CPU J3710 @ 1.60GHz

  • 4 months later...
Posted

---- Minecraft Crash Report ----

WARNING: coremods are present:
  FMLLoadingPlugin (MemoryFix-0.3.jar)
  RenderPlayerAPIPlugin (MouseDelayFix-1.0.jar)
  Glint Colorizer ([1.8.9] GlintColorizer - 1.0.jar)
Contact their authors BEFORE contacting forge

// Daisy, daisy...

Time: 7/24/20 6:23 PM
Description: Initializing game

java.lang.NullPointerException: Initializing game
    at net.minecraftforge.fml.common.Loader$ModIdComparator.compare(Loader.java:375)
    at net.minecraftforge.fml.common.Loader$ModIdComparator.compare(Loader.java:370)
    at java.util.TreeMap.getEntryUsingComparator(TreeMap.java:376)
    at java.util.TreeMap.getEntry(TreeMap.java:345)
    at java.util.TreeMap.get(TreeMap.java:278)
    at com.google.common.collect.AbstractMapBasedMultimap.put(AbstractMapBasedMultimap.java:192)
    at com.google.common.collect.AbstractSetMultimap.put(AbstractSetMultimap.java:121)
    at com.google.common.collect.TreeMultimap.put(TreeMultimap.java:78)
    at net.minecraftforge.fml.common.Loader.identifyDuplicates(Loader.java:386)
    at net.minecraftforge.fml.common.Loader.identifyMods(Loader.java:364)
    at net.minecraftforge.fml.common.Loader.loadMods(Loader.java:488)
    at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:208)
    at net.minecraft.client.Minecraft.func_71384_a(Minecraft.java:417)
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:329)
    at net.minecraft.client.main.Main.main(SourceFile:124)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:28)


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Stacktrace:
    at net.minecraftforge.fml.common.Loader$ModIdComparator.compare(Loader.java:375)
    at net.minecraftforge.fml.common.Loader$ModIdComparator.compare(Loader.java:370)
    at java.util.TreeMap.getEntryUsingComparator(TreeMap.java:376)
    at java.util.TreeMap.getEntry(TreeMap.java:345)
    at java.util.TreeMap.get(TreeMap.java:278)
    at com.google.common.collect.AbstractMapBasedMultimap.put(AbstractMapBasedMultimap.java:192)
    at com.google.common.collect.AbstractSetMultimap.put(AbstractSetMultimap.java:121)
    at com.google.common.collect.TreeMultimap.put(TreeMultimap.java:78)
    at net.minecraftforge.fml.common.Loader.identifyDuplicates(Loader.java:386)
    at net.minecraftforge.fml.common.Loader.identifyMods(Loader.java:364)
    at net.minecraftforge.fml.common.Loader.loadMods(Loader.java:488)
    at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:208)
    at net.minecraft.client.Minecraft.func_71384_a(Minecraft.java:417)

-- Initialization --
Details:
Stacktrace:
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:329)
    at net.minecraft.client.main.Main.main(SourceFile:124)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:28)

-- System Details --
Details:
    Minecraft Version: 1.8.9
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 1.8.0_51, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 323330624 bytes (308 MB) / 536870912 bytes (512 MB) up to 2147483648 bytes (2048 MB)
    JVM Flags: 8 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx2G -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
    IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
    FML: MCP 9.19 Powered by Forge 11.15.1.1722 16 mods loaded, 0 mods active
    States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored
        mcp{9.19} [Minecraft Coder Pack] (minecraft.jar) 
        FML{8.0.99.99} [Forge Mod Loader] (forge-1.8.9-11.15.1.1722.jar) 
        Forge{11.15.1.1722} [Minecraft Forge] (forge-1.8.9-11.15.1.1722.jar) 
        Glint-Colorizer{1.0} [Glint Colorizer] (minecraft.jar) 
        RenderPlayerAPI{1.0} [Render Player API] (minecraft.jar) 
        perspectivemod{1.0} [Perspective Mod] ([1.8.9] Perspective Mod [fix2].jar) 
        wingsmod{1.2} [Wings Mod] ([1.8.9] Wings Mod-1.2.jar) 
        autogg{2.0.4} [Auto GG] (AutoGG-2.0.4 (1.8.9).jar) 
        autotip{2.0.3} [Autotip] (Autotip-2.0.3 [1.8-1.11.2].jar) 
        customtag{1.0} [CustomTAG Mod] (CustomTAG-1.0.jar) 
        memoryfix{0.3} [MemoryFix] (MemoryFix-0.3.jar) 
        null{1.0} [null] (MinecraftCapes+Forge+1.16.1-v10.jar) 
        oldanimations{2.3} [oldanimations] (OldAnimationsMod v2.3.1 FORGE MC1.8.9.jar) 
        quickplay{1.2.10} [QuickPlay] (QuickPlay-1.8.9-1.2.10.jar) 
        timechanger{1.0} [TimeChanger] (TimeChanger-1.0 (1.8.9).jar) 
        enhancements{7.4} [Vanilla Enhancements] (Vanilla Enhancements-7.4.jar) 
    Loaded coremods (and transformers): 
FMLLoadingPlugin (MemoryFix-0.3.jar)
  io.prplz.memoryfix.ClassTransformer
RenderPlayerAPIPlugin (MouseDelayFix-1.0.jar)
  api.player.forge.RenderPlayerAPITransformer
Glint Colorizer ([1.8.9] GlintColorizer - 1.0.jar)
  me.powns.glintcolorizer.asm.itemrender.RenderItemTransformer
    GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.6.0 NVIDIA 451.48' Renderer: 'GeForce GTX 1070/PCIe/SSE2'
    Launched Version: 1.8.9-forge1.8.9-11.15.1.1722
    LWJGL: 2.9.4
    OpenGL: GeForce GTX 1070/PCIe/SSE2 GL version 4.6.0 NVIDIA 451.48, NVIDIA Corporation
    GL Caps: Using GL 1.3 multitexturing.
Using GL 1.3 texture combiners.
Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported.
Shaders are available because OpenGL 2.1 is supported.
VBOs are available because OpenGL 1.5 is supported.

    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'fml,forge'
    Type: Client (map_client.txt)
    Resource Packs: !       §b§lSpeedfault §8[§f16§7x§8].zip
    Current Language: English (US)
    Profiler Position: N/A (disabled)
    CPU: 12x Intel(R) Core(TM) i7-5820K CPU @ 3.30GHz

Posted

1.8 is no longer supported on this forum.

Please update to a modern version of Minecraft to receive support.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Guest
This topic is now closed to further replies.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I know that this may be a basic question, but I am very new to modding. I am trying to have it so that I can create modified Vanilla loot tables that use a custom enchantment as a condition (i.e. enchantment present = item). However, I am having trouble trying to implement this; the LootItemRandomChanceWithEnchantedBonusCondition constructor needs a Holder<Enchantment> and I am unable to use the getOrThrow() method on the custom enchantment declared in my mod's enchantments class. Here is what I have so far in the GLM:   protected void start(HolderLookup.Provider registries) { HolderLookup.RegistryLookup<Enchantment> registrylookup = registries.lookupOrThrow(Registries.ENCHANTMENT); LootItemRandomChanceWithEnchantedBonusCondition lootItemRandomChanceWithEnchantedBonusCondition = new LootItemRandomChanceWithEnchantedBonusCondition(0.0f, LevelBasedValue.perLevel(0.07f), registrylookup.getOrThrow(*enchantment here*)); this.add("nebu_from_deepslate", new AddItemModifier(new LootItemCondition[]{ LootItemBlockStatePropertyCondition.hasBlockStateProperties(Blocks.DEEPSLATE).build(), LootItemRandomChanceCondition.randomChance(0.25f).build(), lootItemRandomChanceWithEnchantedBonusCondition }, OrichalcumItems.NEBU.get())); }   Inserting Enchantments.[vanilla enchantment here] actually works but trying to declare an enchantment from my custom enchantments class as [mod enchantment class].[custom enchantment] does not work even though they are both a ResourceKey and are registered in Registries.ENCHANTMENT. Basically, how would I go about making it so that a custom enchantment declared as a ResourceKey<Enchantment> of value ResourceKey.create(Registries.ENCHANTMENT, ResourceLocation.fromNamespaceAndPath([modid], [name])), declared in a seperate enchantments class, can be used in the LootItemRandomChanceWithEnchantedBonusCondition constructor as a Holder? I can't use getOrThrow() because there is no level or block entity/entity in the start() method and it is running as datagen. It's driving me nuts.
    • Hi here is an update. I was able to fix the code so my mod does not crash Minecraft. Please understand that I am new to modding but I honestly am having a hard time understanding how anyone can get this to work without having extensive programming and debugging experience as well as searching across the Internet, multiple gen AI bots (claude, grok, openai), and examining source code hidden in the gradle directory and in various github repositories. I guess I am wrong because clearly there are thousands of mods so maybe I am just a newbie. Ok, rant over, here is a step by step summary so others can save the 3 days it took me to figure this out.   1. First, I am using forge 54.1.0 and Minecraft 1.21.4 2. I am creating a mod to add a shotgun to Minecraft 3. After creating the mod and compiling it, I installed the .jar file to the proper directory in Minecraft and used 1.21.4-forge-54.1.0 4. The mod immediately crashed with the error: Caused by: java.lang.NullPointerException: Item id not set 5. Using the stack trace, I determined that the Exception was being thrown from the net.minecraft.world.item.Item.Properties class 6. It seems that there are no javadocs for this class, so I used IntelliJ which was able to provide a decompiled version of the class, which I then examined to see the source of the error. Side question: Are there javadocs? 7. This method, specifically, was the culprit: protected String effectiveDescriptionId() {      return this.descriptionId.get(Objects.requireNonNull(this.id, "Item id not set"));  } 8. Now my quest was to determine how to set this.id. Looking at the same source file, I determined there was another method:  public Item.Properties setId(ResourceKey<Item> pId) {             this.id = pId;             return this;   } 9. So now, I need to figure out how to call setId(). This required working backwards a bit. Starting from the constructor, I stubbed out the variable p which is of type Item.Properties public static final RegistryObject<Item> SHOTGUN = ITEMS.register("shotgun", () -> new ShotgunItem(p)); Rather than putting this all on one line, I split it up for readability like this: private static final Item.Properties p = new Item.Properties().useItemDescriptionPrefix().setId(rk); Here is was the missing function, setId(), which takes a type of ResourceKey<Item>. My next problem is that due to the apparent lack of documentation (I tried searching the docs on this site) I could not determine the full import path to ResourceKey. I did some random searching on the Internet and stumbled across a Github repository which gave two clues: import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; Then I created the rk variable like this: private static ResourceKey<Item> rk = ResourceKey.create(Registries.ITEM, ResourceLocation.parse("modid:shotgunmod")); And now putting it all together in order: private static ResourceKey<Item> rk = ResourceKey.create(Registries.ITEM, ResourceLocation.parse("modid:shotgunmod")); private static final Item.Properties p = new Item.Properties().useItemDescriptionPrefix().setId(rk); public static final RegistryObject<Item> SHOTGUN = ITEMS.register("shotgun", () -> new ShotgunItem(p)); This compiled and the mod no longer crashes. I still have more to do on it, but hopefully this will save someone hours. I welcome any feedback and if I missed some obvious modding resource or tutorial that has this information. If not, I might suggest we add it somewhere for people trying to write a mod that doesn't crash. Thank you !!!  
    • I will keep adding to this thread with more information in case anyone can help, or at the very least I can keep my troubleshooting organized. I decided to downgrade to 54.1.0 in the hopes that this would fix the issue but it didn't. At least now I am on a "recommended" version. The crash report did confirm my earlier post that the Exception is coming from effectiveDescriptionId(). I'll continue to see if I can find a way to set the ID manually.   Caused by: java.lang.NullPointerException: Item id not set         at java.base/java.util.Objects.requireNonNull(Objects.java:259) ~[?:?]         at TRANSFORMER/[email protected]/net.minecraft.world.item.Item$Properties.effectiveDescriptionId(Item.java:465) ~[forge-1.21.4-54.1.0-client.jar!/:?]         at TRANSFORMER/[email protected]/net.minecraft.world.item.Item.<init>(Item.java:111) ~[forge-1.21.4-54.1.0-client.jar!/:?]         at TRANSFORMER/[email protected]/com.example.shotgunmod.ShotgunItem.<init>(ShotgunItem.java:19) ~[shotgunmod-1.0.0.jar!/:1.0.0]         at TRANSFORMER/[email protected]/com.example.shotgunmod.ModItems.lambda$static$0(ModItems.java:15) ~[shotgunmod-1.0.0.jar!/:1.0.0]         at TRANSFORMER/[email protected]/net.minecraftforge.registries.DeferredRegister$EventDispatcher.lambda$handleEvent      
    • It just randomly stop working after a rebooted my dedicated server PLEASE HELP!   com.google.gson   Failed to start the minecraft server com.google.gson.JsonSyntaxException: Expected a com.google.gson.JsonObject but was com.google.gson.JsonPrimitive; at path $  
  • Topics

×
×
  • Create New...

Important Information

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