Bug. Crash on generation of overlays
wmrojer opened this issue ยท 9 comments
When defining a variant for an ore that have a texture larger then 16 * 16 (animated texture or a loaded resource pack) the game will crash at startup unless I set B:overlaysFromRP=false.
In this case it is Yellorite ore from Extreme Reactors that has a 6 frame animated texture with size 16 * 96. Verified by changing the bitmap i question in the jar file to a 16*16 texture or simply pointing to a different texture file.
---- Minecraft Crash Report ----
WARNING: coremods are present:
OTGCorePlugin (OTG-Core.jar)
Contact their authors BEFORE contacting forge
---- Minecraft Crash Report ----
WARNING: coremods are present:
Contact their authors BEFORE contacting forge
// I let you down. Sorry :(
Time: 3/21/21 7:45 PM
Description: There was a severe problem during mod loading that has caused the game to fail
net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from Ore Stone Variants (osv)
Caused by: java.lang.IllegalArgumentException: Width (16) and height (0) cannot be <= 0
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at java.awt.image.BufferedImage.(Unknown Source)
at com.personthecat.orestonevariants.textures.ImageTools.getImage(ImageTools.java:171)
at com.personthecat.orestonevariants.textures.ImageTools.ensureSizeParity(ImageTools.java:151)
at com.personthecat.orestonevariants.textures.ImageTools.shadeOverlay(ImageTools.java:139)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$generateOverlays$4(SpriteHandler.java:98)
at java.util.Optional.orElseGet(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.generateOverlays(SpriteHandler.java:98)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$handleVariants$1(SpriteHandler.java:76)
at java.util.Optional.ifPresent(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$handleVariants$2(SpriteHandler.java:70)
at java.util.Optional.ifPresent(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.handleVariants(SpriteHandler.java:69)
at com.personthecat.orestonevariants.textures.SpriteHandler.generateOverlays(SpriteHandler.java:55)
at com.personthecat.orestonevariants.proxy.ClientProxy.generateOverlays(ClientProxy.java:33)
at com.personthecat.orestonevariants.Main.preInit(Main.java:74)
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.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:637)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:219)
at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:197)
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 com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:136)
at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:629)
at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:252)
at net.minecraft.client.Minecraft.func_71384_a(Minecraft.java:467)
at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:378)
at net.minecraft.client.main.Main.main(SourceFile:123)
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.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:
-- System Details --
Details:
Minecraft Version: 1.12.2
Operating System: Windows 10 (amd64) version 10.0
Java Version: 1.8.0_281, Oracle Corporation
Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 418766344 bytes (399 MB) / 1073741824 bytes (1024 MB) up to 17179869184 bytes (16384 MB)
JVM Flags: 8 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx16G -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.42 Powered by Forge 14.23.5.2854 17 mods loaded, 17 mods active
States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored
| State | ID | Version | Source | Signature |
|:----- |:------------------- |:----------------- |:---------------------------------------------- |:---------------------------------------- |
| LCH | minecraft | 1.12.2 | minecraft.jar | None |
| LCH | mcp | 9.42 | minecraft.jar | None |
| LCH | FML | 8.0.99.99 | forge-1.12.2-14.23.5.2854.jar | e3c3d50c7c986df74c645c0ac54639741c90a557 |
| LCH | forge | 14.23.5.2854 | forge-1.12.2-14.23.5.2854.jar | e3c3d50c7c986df74c645c0ac54639741c90a557 |
| LCH | appliedenergistics2 | rv6-stable-7 | appliedenergistics2-rv6-stable-7.jar | dfa4d3ac143316c6f32aa1a1beda1e34d42132e5 |
| LCH | baubles | 1.5.2 | Baubles-1.12-1.5.2.jar | None |
| LCH | redstoneflux | 2.1.1 | RedstoneFlux-1.12-2.1.1.1-universal.jar | None |
| LCH | cofhcore | 4.6.6 | CoFHCore-1.12.2-4.6.6.1-universal.jar | None |
| LCH | cofhworld | 1.4.0 | CoFHWorld-1.12.2-1.4.0.1-universal.jar | None |
| LCH | zerocore | 1.12.2-0.1.2.9 | zerocore-1.12.2-0.1.2.9.jar | None |
| LCH | bigreactors | 1.12.2-0.4.5.68 | ExtremeReactors-1.12.2-0.4.5.68.jar | None |
| LCH | forestry | 5.8.2.422 | forestry_1.12.2-5.8.2.422.jar | None |
| LCH | mantle | 1.12-1.3.3.55 | Mantle-1.12-1.3.3.55.jar | None |
| LCH | tconstruct | 1.12.2-2.13.0.183 | TConstruct-1.12.2-2.13.0.183.jar | None |
| LCH | thaumcraft | 6.1.BETA26 | Thaumcraft-1.12.2-6.1.BETA26.jar | None |
| LCH | thermalfoundation | 2.6.7 | ThermalFoundation-1.12.2-2.6.7.1-universal.jar | None |
| LCE | osv | 5.12 | Ore+Stone+Variants-5.12-1.12.jar | None |
Loaded coremods (and transformers):
GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.6.0 NVIDIA 456.71' Renderer: 'GeForce GTX 1060 6GB/PCIe/SSE2'
AE2 Version: stable rv6-stable-7 for Forge 14.23.5.2768
Pulsar/tconstruct loaded Pulses:
- TinkerCommons (Enabled/Forced)
- TinkerWorld (Enabled/Not Forced)
- TinkerTools (Enabled/Not Forced)
- TinkerHarvestTools (Enabled/Forced)
- TinkerMeleeWeapons (Enabled/Forced)
- TinkerRangedWeapons (Enabled/Forced)
- TinkerModifiers (Enabled/Forced)
- TinkerSmeltery (Enabled/Not Forced)
- TinkerGadgets (Enabled/Not Forced)
- TinkerOredict (Enabled/Forced)
- TinkerIntegration (Enabled/Forced)
- TinkerFluids (Enabled/Forced)
- TinkerMaterials (Enabled/Forced)
- TinkerModelRegister (Enabled/Forced)
The texture issues were resolved in ce11f2b4. I'll update here when I'm done with the other issue and have everything all tested.
The Thermal Foundations harvest levels were fixed in 96b1410f. I'll test all of these changes out tonight and update here if all looks good.
Hey, I just got through testing these changes and can confirm that animated textures, scaled dense textures, and the other problems were all definitely fixed. This includes fixes to overlaysFromRP
and other image path-related fixes from 6.0. I'm actually gonna go ahead and release those changes on CurseForge and will close these issues in a few days. Let me know if something is still broken for you or if you need any other changes while I'm still working on OSV for a bit.
Noticed I got a different crash when loading with a resource pack loaded. But maybe that is cause of the same fault. Looks like it also comes from fg and bg images being different sizes.
---- Minecraft Crash Report ----
WARNING: coremods are present:
Contact their authors BEFORE contacting forge
// You should try our sister game, Minceraft!
Time: 3/21/21 9:33 PM
Description: There was a severe problem during mod loading that has caused the game to fail
net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from Ore Stone Variants (osv)
Caused by: java.lang.ArrayIndexOutOfBoundsException: 16
at com.personthecat.orestonevariants.textures.ImageTools.overlay(ImageTools.java:414)
at com.personthecat.orestonevariants.textures.ImageTools.shadeOverlay(ImageTools.java:145)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$generateOverlays$4(SpriteHandler.java:98)
at java.util.Optional.orElseGet(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.generateOverlays(SpriteHandler.java:98)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$handleVariants$1(SpriteHandler.java:76)
at java.util.Optional.ifPresent(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.lambda$handleVariants$2(SpriteHandler.java:70)
at java.util.Optional.ifPresent(Unknown Source)
at com.personthecat.orestonevariants.textures.SpriteHandler.handleVariants(SpriteHandler.java:69)
at com.personthecat.orestonevariants.textures.SpriteHandler.generateOverlays(SpriteHandler.java:55)
at com.personthecat.orestonevariants.proxy.ClientProxy.generateOverlays(ClientProxy.java:33)
at com.personthecat.orestonevariants.Main.preInit(Main.java:74)
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.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:637)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:219)
at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:197)
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 com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
at com.google.common.eventbus.EventBus.post(EventBus.java:217)
at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:136)
at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:629)
at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:252)
at net.minecraft.client.Minecraft.func_71384_a(Minecraft.java:467)
at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:378)
at net.minecraft.client.main.Main.main(SourceFile:123)
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.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:
-- System Details --
Details:
Minecraft Version: 1.12.2
Operating System: Windows 10 (amd64) version 10.0
Java Version: 1.8.0_281, Oracle Corporation
Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 542395456 bytes (517 MB) / 1073741824 bytes (1024 MB) up to 17179869184 bytes (16384 MB)
JVM Flags: 8 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx16G -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.42 Powered by Forge 14.23.5.2854 17 mods loaded, 17 mods active
States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored
| State | ID | Version | Source | Signature |
|:----- |:------------------- |:----------------- |:---------------------------------------------- |:---------------------------------------- |
| LCH | minecraft | 1.12.2 | minecraft.jar | None |
| LCH | mcp | 9.42 | minecraft.jar | None |
| LCH | FML | 8.0.99.99 | forge-1.12.2-14.23.5.2854.jar | e3c3d50c7c986df74c645c0ac54639741c90a557 |
| LCH | forge | 14.23.5.2854 | forge-1.12.2-14.23.5.2854.jar | e3c3d50c7c986df74c645c0ac54639741c90a557 |
| LCH | appliedenergistics2 | rv6-stable-7 | appliedenergistics2-rv6-stable-7.jar | dfa4d3ac143316c6f32aa1a1beda1e34d42132e5 |
| LCH | baubles | 1.5.2 | Baubles-1.12-1.5.2.jar | None |
| LCH | redstoneflux | 2.1.1 | RedstoneFlux-1.12-2.1.1.1-universal.jar | None |
| LCH | cofhcore | 4.6.6 | CoFHCore-1.12.2-4.6.6.1-universal.jar | None |
| LCH | cofhworld | 1.4.0 | CoFHWorld-1.12.2-1.4.0.1-universal.jar | None |
| LCH | zerocore | 1.12.2-0.1.2.9 | zerocore-1.12.2-0.1.2.9.jar | None |
| LCH | bigreactors | 1.12.2-0.4.5.68 | ExtremeReactors-1.12.2-0.4.5.68.jar | None |
| LCH | forestry | 5.8.2.422 | forestry_1.12.2-5.8.2.422.jar | None |
| LCH | mantle | 1.12-1.3.3.55 | Mantle-1.12-1.3.3.55.jar | None |
| LCH | tconstruct | 1.12.2-2.13.0.183 | TConstruct-1.12.2-2.13.0.183.jar | None |
| LCH | thaumcraft | 6.1.BETA26 | Thaumcraft-1.12.2-6.1.BETA26.jar | None |
| LCH | thermalfoundation | 2.6.7 | ThermalFoundation-1.12.2-2.6.7.1-universal.jar | None |
| LCE | osv | 5.12 | Ore+Stone+Variants-5.12-1.12.jar | None |
Loaded coremods (and transformers):
GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.6.0 NVIDIA 456.71' Renderer: 'GeForce GTX 1060 6GB/PCIe/SSE2'
AE2 Version: stable rv6-stable-7 for Forge 14.23.5.2768
Pulsar/tconstruct loaded Pulses:
- TinkerCommons (Enabled/Forced)
- TinkerWorld (Enabled/Not Forced)
- TinkerTools (Enabled/Not Forced)
- TinkerHarvestTools (Enabled/Forced)
- TinkerMeleeWeapons (Enabled/Forced)
- TinkerRangedWeapons (Enabled/Forced)
- TinkerModifiers (Enabled/Forced)
- TinkerSmeltery (Enabled/Not Forced)
- TinkerGadgets (Enabled/Not Forced)
- TinkerOredict (Enabled/Forced)
- TinkerIntegration (Enabled/Forced)
- TinkerFluids (Enabled/Forced)
- TinkerMaterials (Enabled/Forced)
- TinkerModelRegister (Enabled/Forced)
Thank you.
I noticed that some of the default setting Thermal Foundation ores had some miss-matching harvest level settings. Is that something you want to know?
Sure, if you have the values. I don't usually just track of the updated mod support values for 1.12 since it's too much to maintain, but I'm happy to do it in this case.
Thanks a lot for your help! Feel free to join the Discord for updates on all of this. I'm working on major updates to Cave Generator first, so it'll probably take a couple days before I get to these.