Stormwind99 / FoodFunk

Minecraft mod: What is that funky smell in my backpack? Food spoils over time unless preserved. Configure any item to rot, any container to preserve items.
https://minecraft.curseforge.com/projects/food-funk
GNU Lesser General Public License v3.0
10 stars 8 forks source link

Foods rot instantly if doDaylightCycle is false #21

Closed esotericist closed 6 years ago

esotericist commented 6 years ago

Now, obviously the concept of food funk and "pausing game time" aren't inherently compatible, but when I'm doing testing/mod configuration for my modpack, I tend to pause time so I don't have to deal with day/night cycles. I also tend to pause day/night at the start of a server reset, so that I have time to get chunks generated, and things generally stabilized before players get involved.

If the problem stopped as soon as I turned doDaylightCycle back to true, it wouldn't be so bad, but it seems like the longer the server runs with the daylight cycle disabled, the more this is a problem, I can only guess due to the increasing mismatch between getWorldTime() and getTotalWorldTime() (since the value of getWorldTime() freezes when the daylight cycle is paused, but getTotalWorldTime() does not). It takes quite some time for things to start working as expected again.

I don't know if this is something you can address, but I thought you should be aware that this could be a problem. And, ideally, food rot should pause when doDaylightCycle is false, since I sometimes also do that for server maintenance (such as if I need to clean up after some kind of catastrophe, be it mod or player originated).

za3k commented 6 years ago

I have played on survival servers with doDaylightCycle=False so I am not sure it makes sense to pause it always.

Stormwind99 commented 6 years ago

I have not been able to duplicate this problem (foods rot instantly if doDaylightCycle is false) in the latest unreleased code base.

Stormwind99 commented 6 years ago

Please re-test in version 4.2.0 since I can't reproduce the issue.

We should also create another issue for the "pause all rot" request - that will be a toughy due to the system being an event and global time based system.