AppleCore

AppleCore

56M Downloads

FoodStats incompatible with Sponge

squeek502 opened this issue · 1 comments

commented

See squeek502/SpiceOfLife#99 and SpongePowered/SpongeForge#969 and SpongePowered/SpongeForge#916

Sponge re-initializes FoodStats without the EntityPlayer field added by AppleCore, causing the player to be null unexpectedly.

Not sure how to best resolve this yet.

Some possible fixes:

  • Set the player if it's null every FoodStats.onUpdate. This would basically be a band-aid, and would still fail before the first onUpdate call, but it might work to help resolve issues like this in the future
  • ASM into the modified Sponge code and insert the EntityPlayer into the FoodStats constructor.
commented

Should be fixed with SpongePowered/Sponge@384180f.