SilentChaos512/Tutorial-Mod

Item Models and Block Models not Generating

Opened this issue · 7 comments

I read the other issue and after adding all the code to my build.gradle and etc. I still keep having problems. The issue is that the models do not generate AT ALL.

attached is the log file

and here is what was in the console of intelliJ:

[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid forge : RegistryEvent.Registerminecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid forge : RegistryEvent.Registerminecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid legitmod : RegistryEvent.Registerminecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid legitmod : RegistryEvent.Registerminecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.re.GameData/REGISTRIES]: Applying holder lookups: minecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.re.GameData/REGISTRIES]: Holder lookups applied: minecraft:worldgen/tree_decorator_type
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid forge : net.minecraftforge.fml.event.lifecycle.GatherDataEvent@6ddccee4
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid forge : net.minecraftforge.fml.event.lifecycle.GatherDataEvent@6ddccee4
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Firing event for modid legitmod : net.minecraftforge.fml.event.lifecycle.GatherDataEvent@58fa8762
[01:30:09] [main/DEBUG] [ne.mi.fm.ja.FMLModContainer/LOADING]: Fired event for modid legitmod : net.minecraftforge.fml.event.lifecycle.GatherDataEvent@58fa8762
[01:30:09] [main/INFO] [minecraft/DataGenerator]: Starting provider: Block States: legitmod
Exception in thread "main" [01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:39)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at cpw.mods.modlauncher.Launcher.run(Launcher.java:82)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at cpw.mods.modlauncher.Launcher.main(Launcher.java:66)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1052]: at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: Caused by: java.lang.reflect.InvocationTargetException
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at java.lang.reflect.Method.invoke(Method.java:498)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at net.minecraftforge.userdev.FMLUserdevDataLaunchProvider.lambda$launchService$0(FMLUserdevDataLaunchProvider.java:51)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.ThreadGroup:uncaughtException:1061]: ... 5 more
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: Caused by: java.lang.IllegalArgumentException: Texture legitmod:block/legitimite_block does not exist in any known resource pack
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at com.google.common.base.Preconditions.checkArgument(Preconditions.java:191)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.ModelBuilder.texture(ModelBuilder.java:149)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.ModelProvider.singleTexture(ModelProvider.java:175)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.ModelProvider.singleTexture(ModelProvider.java:170)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.ModelProvider.cubeAll(ModelProvider.java:179)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.BlockStateProvider.cubeAll(BlockStateProvider.java:172)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.BlockStateProvider.simpleBlock(BlockStateProvider.java:176)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at com.legitmyth.legitmod.data.client.ModBlockStateProvider.registerStatesAndModels(ModBlockStateProvider.java:16)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.client.model.generators.BlockStateProvider.act(BlockStateProvider.java:108)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraft.data.DataGenerator.run(DataGenerator.java:53)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.fml.event.lifecycle.GatherDataEvent$DataGeneratorConfig.lambda$runAll$0(GatherDataEvent.java:111)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at cpw.mods.modlauncher.api.LamdbaExceptionUtils.lambda$rethrowConsumer$0(LamdbaExceptionUtils.java:34)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at java.util.HashMap$Values.forEach(HashMap.java:981)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.fml.event.lifecycle.GatherDataEvent$DataGeneratorConfig.runAll(GatherDataEvent.java:107)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraftforge.fml.DatagenModLoader.begin(DatagenModLoader.java:61)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: at net.minecraft.data.Main.main(Main.java:43)
[01:30:09] [main/INFO] [STDERR/]: [java.lang.Throwable:printStackTrace:644]: ... 11 more

Task :runData FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':runData'.

Process 'command 'C:\Program Files\Java\jdk1.8.0_271\bin\java.exe'' finished with non-zero exit value 1

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/4.10.3/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 11s
10 actionable tasks: 5 executed, 5 up-to-date
1:30:10 AM: Task execution finished 'runData'.
latest.log

TauKL commented

is this why?
Texture legitmod:block/legitimite_block does not exist in any known resource pack

Your texture does not exist. Maybe you named one of your folders or even the file itself incorrectly. Assuming you created the PNG file at all, of course.

I have a similar problem , my textures do exist and when i run the gradle ``runData``` task the data generators do not produce any data, and in game no textures, They did work but not now. this is my mod, i've only added an extra item and deleted the previous generators output

The data providers "get loaded" but their functions do not because for example this in my block state provider does not get ran, I have added a few more debug messages, and a lot more blocks, but same idea

Now after an environment reset and IntelliJ update, my event handler functions are now ran, but it seems like they dont save :(

Make sure your mod id in the run data args section in build.gradle is correct

Now working for me!