Content: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Background: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Pattern: Blank Waves Notes Sharp Wood Rockface Leather Honey Vertical Triangles
Welcome to TerraFirmaCraft Forums

Register now to gain access to all of our features. Once registered and logged in, you will be able to contribute to this site by submitting your own content or replying to existing content. You'll be able to customize your profile, receive reputation points as a reward for submitting content, while also communicating with other members via your own private inbox, plus much more! This message will be removed once you have signed in.

  • Announcements

    • Dries007

      Server Move   09/13/2018

      I (Dries007) have recently taken over as main developer and server admin. This involved moving servers to reduce cost. It's likely there will be some more downtime in the future but most  things should be sorted by now. This forum is in dire need of replacement as the software is quite old and can't be easily updated. If you wish to discuss or stay updated, join our discord: https://invite.gg/terrafirmacraft. The forum will remain available to read, but will be locked in the future, when a new system is setup. The forum and wiki are now ad free. If you'd like to contribute to keeping it that way, you can do so via paypal or patreon.
Mikko_blu

[Solved] Quick question about food decay

7 posts in this topic

Hi there.

 

I just had a few questions about food decay - i was a little confused and i apologize.

 

In an earlier post, Kittychanley mentioned about food decay:

Example 1: Start with a raw porkchop. Salt it, smoke it, cook it, and then place it in a vessel. This results in (0.75)*(0.75)*(0.75)*(0.5) = 0.21, meaning that the porkchop will decay at 21% the rate compared to the original raw piece.

 

 

Does this mean that food will decay 21% slower, or 89% slower?

 

And then, on the wiki, under Cooking it said (this is more about the rates, not the specific form of preservation):

 

While cooked food has a decay modifier of 0.75, it affects the effectiveness of other preservation methods. For example, salted raw beef will simply have the salted 0.5 modifier, while salted cooked beef has a modifier of cooked 0.75 * salted 0.75 = 0.5625.

 

Does this mean that cooked food decays 75% slower, or 25% slower? I'd imagine 25%, but i wanted to ask to cover bases.

 

Thank you ahead of time for any support you can give me, I've just made my giant fridge and now i'm trying to understand the processes a little better!

 

0

Share this post


Link to post
Share on other sites

For example-

Raw pork- decay per day- 1 oz from 160 oz

Salted- 1x0,75 oz / day

Salted+cooked- 1x0,75x0,75 oz

0

Share this post


Link to post
Share on other sites

In all of those examples, your starting decay rate is 1. 1*0.75 = 0.75. 0.75 is 75% of 1, so the food decays at 75% the rate that it would without the preservation. I.E. 25% slower.

 

Modifiers stack; the more you put on, the smaller the number gets, and the slower the food decays.

1

Share this post


Link to post
Share on other sites

I have an additional question regarding decay rate modifiers:

Do they really all basically just stack? Then the wiki might be expanded by a modifier table.

 

The wiki states "salted (0.5)" is better than "cooked and salted (0,75*0,75 = 0,5625 )". This seems like a typo and might be "cooked and salted (0,75 * 0,5 = 0.375 ) if "cooked" does not affect "salted" modifier. If it does - what is the use of cooking it?

 

 I never tried, but can pickled food be salted? The wiki states "pickled raw food has a modifier of 0.5". What about pickled smoked food?

 

Dried food as a exceptional good modifier of 0.25. Stacking this with the "vessel" modifier of 0.5 which gives it 0.125 in total. Dried cooked food is not possible.

 

Thus the statement of the wiki "There are many different ways to preserve food.." and the previous comment "they all stack" isn't that true or should at least be relativized.

 

Any further information would be greatly appreciated. I would love to support the wiki too. Unfortunaltey this is nothing anyone should or could change quickly in the wiki.

Edited by McOrigin
0

Share this post


Link to post
Share on other sites

Yes, they all just stack, with the exception of pickling and salted, and cooking and drying, which is why the wiki explicitly states "There are many different ways to preserve food and change the rate at which it decays. Each method results in a decay modifier, meaning that if two methods stack together, the resulting effect on the decay is a multiplier equal to the two method modifiers multiplied together. Salting and Pickling are the two methods that will not stack multipliers when used in combination."

 

"Cheese and brined meats can be hung on a smoke rack to smoke and/or dry the food. All smoked foods have a decay modifier of 0.75, while dried food has a decay modifier of 0.25. Note: Cooking dried food removes the dried decay modifier."

 

Cooking food intentionally decreases the effectiveness of all other modifiers. The use of cooking it is that you cannot eat raw meat, and it must be cooked.

 

Pickled food can be salted, but it won't do anything. See above statement. Pickled smoked food will stack the modifiers.

 

Dried cooked food is possible. In fact, you actually must cook dried meat before you are able to eat it. As stated above, cooking dry meat just removes the dried modifier.

 

Here's the code for how the base decay rate on food is determined. External modifiers such as storage methods will then stack on top of this value. So in essence, "They all stack" considering that the majority of them stack with each other, with very few exceptions is basically true. If it really bothers you that much, I will change it to say "They pretty much all stack"

 

https://github.com/Deadrik/TFCraft/blob/b3e79e92e938765edf05b26e1cc9b03d8f9aa7b8/src/Common/com/bioxx/tfc/Food/ItemFoodTFC.java#L150

	@Override	public float getDecayRate(ItemStack is)	{		float mult = 1.0f;		if(Food.isCooked(is))		{			mult *= 0.75f;			if(Food.isPickled(is) || Food.isSalted(is))				mult *= 0.75f;			if(Food.isSmoked(is))				mult *= 1f - (0.25f * this.getSmokeAbsorbMultiplier());		}		else		{			if(Food.isPickled(is) || Food.isSalted(is))				mult *= 0.5f;			if(Food.isSmoked(is))				mult *= 1f - (0.25f * this.getSmokeAbsorbMultiplier());			if(Food.isDried(is))				mult *= 0.25f;		}		return decayRate * (TFC_Time.getYearRatio(96)) * mult;	}
0

Share this post


Link to post
Share on other sites

So my Pickled Salted Dried Pork was useless and i don't need to salt it at all.

0

Share this post


Link to post
Share on other sites

In all of those examples, your starting decay rate is 1. 1*0.75 = 0.75. 0.75 is 75% of 1, so the food decays at 75% the rate that it would without the preservation. I.E. 25% slower.

 

Modifiers stack; the more you put on, the smaller the number gets, and the slower the food decays.

Alright, thank you very much. I was just making sure it was 75% of 1, and not 100% decay rate only reduced to 75% decay.

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now