You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
java.lang.NullPointerException: Cannot invoke "java.lang.Float.floatValue()" because the return value of "java.util.Map.get(Object)" is null
at com.illusivesoulworks.diet.common.capability.PlayerDietTracker.apply(PlayerDietTracker.java:340) ~[%5B均衡饮食%5D%20diet-forge-2.1.1+1.20.1.jar%23306!/:2.1.1+1.20.1] {re:classloading}
at com.illusivesoulworks.diet.common.capability.PlayerDietTracker.consume(PlayerDietTracker.java:177) ~[%5B均衡饮食%5D%20diet-forge-2.1.1+1.20.1.jar%23306!/:2.1.1+1.20.1] {re:classloading}
at com.illusivesoulworks.diet.common.capability.DietCapabilityEventsListener.lambda$finishItemUse$2(DietCapabilityEventsListener.java:118) ~[%5B均衡饮食%5D%20diet-forge-2.1.1+1.20.1.jar%23306!/:2.1.1+1.20.1] {re:classloading}
at net.minecraftforge.common.util.LazyOptional.ifPresent(LazyOptional.java:137) ~[forge-1.20.1-47.3.1-universal.jar%23387!/:?] {re:mixin,re:classloading}
at com.illusivesoulworks.diet.common.capability.DietCapabilityEventsListener.finishItemUse(DietCapabilityEventsListener.java:118) ~[%5B均衡饮食%5D%20diet-forge-2.1.1+1.20.1.jar%23306!/:2.1.1+1.20.1] {re:classloading}
at com.illusivesoulworks.diet.common.capability.__DietCapabilityEventsListener_finishItemUse_Finish.invoke(.dynamic) ~[%5B均衡饮食%5D%20diet-forge-2.1.1+1.20.1.jar%23306!/:2.1.1+1.20.1] {re:classloading,pl:eventbus:B}
at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:73) ~[eventbus-6.0.5.jar%23137!/:?] {}
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:315) ~[eventbus-6.0.5.jar%23137!/:?] {}
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:296) ~[eventbus-6.0.5.jar%23137!/:?] {}
at net.minecraftforge.event.ForgeEventFactory.onItemUseFinish(ForgeEventFactory.java:396) ~[forge-1.20.1-47.3.1-universal.jar%23387!/:?] {re:classloading}
...
The text was updated successfully, but these errors were encountered:
I used the exclusion method to think about the difference between before and after the datapack modification.
The exception seems to have occurred after I removed the default food group configuration (e.g. fruit.json, vegetables.json) under the tag/items/ directory.
I added them back and no more crashes.
I can play normally now, but I hope this information will help you troubleshoot the problem, or explain why I can't remove the default configuration e.g. fruit.json.
Minecraft Version
1.20.1
What happened?
The game crashed after I ate an apple
The crash log shows that this mod caused the crash
It is also possible that the crash is not caused by mod code, but my datapack configuration problem, please correct
How do you trigger this bug?
The following is the datapack:
I thought it was configured correctly.
Loader
Forge
Loader Version
Forge 47.3.1
API Version
No response
Mod Version
diet-forge-2.1.1+1.20.1
Relevant Log Outputs
The text was updated successfully, but these errors were encountered: