Help me simplify my idea?
I'm still working on my very complicated game (society simulator). One of my idea is change projects - that given enough time, objects can turn into other objects if they are inside a "machine" (pot, drying cloth, fire pit, oven). This doesn't require player characters to actively do things to advance the project, but for each project type, certain conditions must be met. So far, I have only worked with projects that require an ongoing fire. When ever a user sees the fire pit on the items page, it checks if there is a fire, if there is fuel for said fire, and if not, what time does the fire go out? I have this part figured out. But I need a similar system for presence of fresh water, brine and sunlight.
For soaking, there needs to be water and the amount of water must be large enough in relation to the amount of soakable resource (such as beans). So technically it needs to cover them. If I wanted to make things more complicated, I could also make it so that if there is less water than needed, part of the resource will eventually get converted, but that would require splitting the pile, which I would rather not do.
Then there's fermenting. It's similar to soaking except instead of fresh water, you have brine. If we want to get very technical, you should start with brine that has salinity of 12-14% and increase the salinity by 2% every 2 or 3 weeks. I might be okay with skipping that part, and agree that okay, you just need to check that brine is present and use a fixed salinity.
Likewise, if you are tanning hides using vegetable tanning, technically you need to start with a mild solution, then switch into a stronger solution gradually, because if you tossed the hides into the strongest solution straight off the bat, they would only tan on the surface and the inside would be left unchanged. I might also want to keep track of the level of bacteria in the tanning solution, and if the user doesn't change it often enough, the hides will start deteriorating.
For the drying cloth, it needs to check if it has rained since the last time it was checked and if yes, somehow set the condition of the dryable stuff into "wet", which will mean they take a longer time to dry and can potentially rot or get moldy. Weather is recalculated hourly in places that have someone checking and stored in a table. If no one checks the weather then it just assumes it was irrelevant. Each pile of a resource is a row in the objects table, and once it has dried for a long enough time, it will change the object type from normal resource to dried resource. So there are no different levels of dryness currently, either something is dried or it's fresh, there is no gray area. I do have an object status table that is currently used to record things like how much blood an animal has left, or if a flammable object is on fire or not. So technically I could also use it to keep track of dryness/wetness, but then I would have to duplicate the rows when ever the pile is split. Or what if someone merged two piles with different dryness levels? Should that even be possible? IRL if you put raisins and grapes in the same bowl, anybody would be able to tell the difference and be able to separate them into two groups.
Each time the user views the machine, it should check 1) are there things inside that are capable of changing and 2) are the other conditions met. How should I define the conditions in the database?