Project Zomboid

Project Zomboid

No Food Expiration For Unstable
50 Comments
Sheff  [author] 28 Sep @ 3:57pm 
Okay. Good to know. My best guess right now is that because the actual file structure of food recipes changed, that any food that loaded in while the mod was active is different somehow than new food that is generated. Just one of the perils of the Unstable branch I guess. :)

The good news is that I do have a bit of knowledge of Java, so if the mod architecture eventually moves out of .txt files and into something Java oriented I can still probably figure it out.
oxoLIVINGoxo 28 Sep @ 3:00pm 
sorry existing save I mean.
oxoLIVINGoxo 28 Sep @ 3:00pm 
@Sheff I am playing my world and when I go to a new area the food does not say fresh so it is working on an exiting mod when you go to a new area where the food had not been discovered yet!
oxoLIVINGoxo 28 Sep @ 2:42pm 
Thank you so much again!
Chocomeowmeowmeowmeowmeow 28 Sep @ 9:53am 
Appreciated the update <3
Sheff  [author] 28 Sep @ 9:42am 
Hey. Should be updated now. Turns out it was a more significant change than just chocolate milk -- the file structure for every food item got moved around, so it took me a minute to figure that out.

Also, on my quick test, I wasn't able to apply it to an existing save anymore. i.e., I started a game without the mod, then enabled it, and food continued to expire. I don't know why that is yet. But it works on a fresh game when enabled. I'll keep doing a little testing but at least for now it works on new saves.
oxoLIVINGoxo 26 Sep @ 4:52pm 
Thanks Sheff!
Sheff  [author] 26 Sep @ 2:29pm 
Yeah, I had a feeling that adding happiness to chocolate milk would break it. I'll try and get an update out by late tonight or tomorrow.
oxoLIVINGoxo 26 Sep @ 8:27am 
Thanks for the confirmation, Ahmed!
Ahmed 26 Sep @ 12:48am 
same, stopped working on 42.12
oxoLIVINGoxo 25 Sep @ 3:25pm 
@Sheff. I don't know if anyone else is having a problem but your mod is not working on the newest update! Thanks!
oxoLIVINGoxo 1 Sep @ 9:41am 
Still love this mod!
Sheff  [author] 20 Aug @ 8:00am 
When a food rots, it becomes a new item -- you could probably un-rot it, but this mod doesn't do that. Food that is stale *should* stay edible. Food that was fresh will stay edible. Any new food you find will be edible (including in six months later and other delayed-start games).
Maxx75 20 Aug @ 2:54am 
So all new Food that i found will no longer Rotten? But that what i have before this Mod will do?
Sheff  [author] 19 Aug @ 4:14pm 
In your raw files, there are two parameters that control when food transitions from fresh to no longer fresh, and from no longer fresh to fully rotted. This mod is a set of modified raw files that don't contain that parameter. So other mods that add or remove foods will not work with it, because they overwrite it.

The solution to fixing that is LUA-based -- you just execute the same process that this mod does, but you do it at the end of the mod load order so that any new foods added also lose their fresh and rotten parameters. But since I don't know how to script in LUA, that isn't a fix that I've been able to implement.
Maxx75 19 Aug @ 1:40pm 
How does it exactly work? My Food still rots in the normal refrigerator
elspbeth 7 Aug @ 3:17am 
How much do I love you....let me count.....I love you I love you I love you! Thank you for updating the best mod in PZ, you are so greatly appreciated. 90% of my mods are still broken (weep), but here you show up, bringing light back to PZ.
Sheff  [author] 6 Aug @ 2:44pm 
It's doable, but requires more LUA knowledge than I have currently. One of these days, when I have the free time, I've been meaning to work on it.
oanthero 6 Aug @ 11:59am 
Hi @Sheff!

Everything’s working now! No more spoiled food on the menu! I really appreciate it!
If you ever manage to make it compatible with Sapph's Cooking [B42+], it would be perfect!
Link: https://gtm.steamproxy.vip/sharedfiles/filedetails/?id=3409143790
Sheff  [author] 6 Aug @ 9:33am 
Should be updated. The fried chicken place I went to had chicken and milk that didn't expire. However, this version didn't generate a new farming items file -- it's possible there may be some wonkiness with any new farming crops that were in v.11. If anything is still rotting I can take a closer look, just let me know.
oanthero 6 Aug @ 9:05am 
Hi @Sheff!

Version 4.11 really broke the mod. We're eagerly waiting for your update.
Thanks for the great work! I usually play in "isolated in the forest" mode, and your mod really helps me avoid losing my fish and hunted meat.
1000W 5 Aug @ 8:50am 
My mod broke this time, so I'm waiting for an update! Thank you for making the good mode. If you make the [Sapph's Cooking] mode compatible, I love you😂)
manju 5 Aug @ 8:26am 
Thank you!
bociek139 5 Aug @ 7:05am 
Thank u for updating u are amazing
Sheff  [author] 5 Aug @ 6:32am 
Thanks for the heads up -- I'll be able to update it later today.
manju 4 Aug @ 11:20pm 
Its broken :(
Feu 4 Aug @ 9:31pm 
the mod is error in new update
bociek139 8 Jul @ 4:05pm 
Very nice mod for chill playthrough thank u :)
Sheff  [author] 22 May @ 3:19pm 
Updated it, played for week, game loads and I don't see any food expiring. If you find specific items that spoil let me know, there may be changes that I don't currently account for.
sean.adams243634 22 May @ 2:53pm 
doesn't work. game wont start
Sheff  [author] 22 May @ 8:41am 
Roger that, I can get to it later today.
Winsom3r 22 May @ 7:58am 
Confirmed that this doesn't work for 42.8
黑暗老法师 22 May @ 1:50am 
42.8报错
oxoLIVINGoxo 24 Mar @ 8:43pm 
Just tried it! Yay it fixed it! Thank you so much! you rock and again love your mod!
Sheff  [author] 24 Mar @ 7:09pm 
Updated to account for new items, and the game now loads for me and is able to successfully smash a pumpkin. If it still doesn't work, it may be a conflict with another mod.
Sheff  [author] 24 Mar @ 6:13pm 
There's a 2GB update to my Project Zomboid right now -- looks like some things have probably changed in the food department. :) I'll get it fixed later tonight.
oxoLIVINGoxo 24 Mar @ 5:06pm 
@Sheff I am having an error where my game wont load with your mod on after this last update. Love the mod btw and thabks for everything!
ERROR: General f:0, t:1742860550380> ExceptionLogger.logException> Exception thrown
java.lang.Exception: Item not found: Base.PumpkinSmashed at OutputMapper.getItem(OutputMapper.java:127).
Sheff  [author] 5 Mar @ 10:44am 
The egg issue was from the update to 42.4.0. Should be working now, trying to find some egg-laying birds in the debug file that I set up. :)
Sheff  [author] 4 Mar @ 4:19pm 
Interesting. I'll take a look and see if I can figure out why that is.
oxoLIVINGoxo 4 Mar @ 12:09am 
When I cooked the eggs they stopped saying fresh!
oxoLIVINGoxo 3 Mar @ 11:48pm 
Also just harvested some eggs and the ones that are -7 hunger are good but the ones that are -8 are saying fresh on them. I really don't care cause this mod is awesomeness but I just wanted to let you know!
Sheff  [author] 1 Mar @ 3:55pm 
You should be able to add it to any existing save and it will return any non-stale, non-spoiled foods to their normal state. Just be careful with removing it -- I don't remember the last time that I tested it, but I believe that it'll make all food in your game stale if removed.
oxoLIVINGoxo 1 Mar @ 11:31am 
I was wondering if there is any way to get this mod to work on a world that I had before the mod? If you can how? Thank you and have a wonderful day!
By the way on my new world I started, tested out the mod and I love it. I downloaded and wanted this because my game is bugging out. I put my sandbox settings at very slow decay and no decay in refrigerators and with in 10 days all my food is stale in a frigde! So this mod is a God send! lol Thanks
Sheff  [author] 1 Feb @ 4:36pm 
Pushed a new version now that appears to fix the issues with bacon, mayonnaise, cabbage, potatoes, and other food obtained from farming continuing to spoil (the farming.txt items weren't correctly being located by the Python script I'm using).

Continue to let me know if you find any other items that are still spoiling.
robertovega1034 1 Feb @ 1:04pm 
it says still "fresh" tag on food can you fix
..::[the_mobkiller]::.. 31 Jan @ 9:16pm 
I had a run yesterday where I found some bacon and mayo in a fridge that still had expiration on them. Anything else so far was forever good.
Jian_. 30 Jan @ 5:02pm 
i love this :D
Sheff  [author] 30 Jan @ 3:35pm 
Using this mod, almost no food will spoil. Anywhere that it can find a "DaysFresh" or "DaysTotallyRotten" parameter, it removes that parameter. There's a very small handful of items that this mod isn't able to touch because they're buried deeper in the Lua, like the soup/stew that you can find pre-spawned, but virtually everything else will remain edible forever.
Nerssaum 30 Jan @ 7:45am 
Doesn't all food spoil? or just the ones the player does?
Sheff  [author] 29 Jan @ 9:53pm 
Just a disclaimer -- I spent about ten minutes testing this, and it works. It's entirely possible that there's random edge cases that I missed, because the difference in food recipes between B41 and B42 is pretty significant. If you find something rotting that isn't supposed to, drop a comment here and I'll take a look. You can also reach me on Discord, my name there is just Sheff.