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

      ATTENTION Forum Database Breach   03/04/2019

      There has been a breach of our database. Please make sure you change your password (use a password manager, like Lastpass).
      If you used this password anywhere else, change that too! The passwords themselves are stored hashed, but may old accounts still had old, insecure (by today's standards) hashes from back when they where created. This means they can be "cracked" more easily. Other leaked information includes: email, IP, account name.
      I'm trying my best to find out more and keep everyone up to date. Discord (http://invite.gg/TerraFirmaCraft) is the best option for up to date news and questions. I'm sorry for this, but the damage has been done. All I can do is try to make sure it doesn't happen again.
    • Claycorp

      This forum is now READ ONLY!   01/20/2020

      As of this post and forever into the future this forum has been put into READ ONLY MODE. There will be no new posts! A replacement is coming SoonTM . If you wish to stay up-to-date on whats going on or post your content. Please use the Discord or Sub-Reddit until the new forums are running.

      Any questions or comments can be directed to Claycorp on either platform.
Sign in to follow this  
Followers 0
Michidez

Monotone Food

14 posts in this topic

I was thinking the other night about how potatoes changed the way of living of the europeans. Because potatoes have a mutch higher nutrition value then wheat they only grew potatoes.Their food became monotone and they got ill. So I thought how about changing it that if you eat pork meat multiple times it reduces the amount of food it adds on the foodbar. This woud make the new argiculture (and I hope butchering comes in to) mutch more... awesome. :)

0

Share this post


Link to post
Share on other sites

I was thinking the other night about how potatoes changed the way of living of the europeans. Because potatoes have a mutch higher nutrition value then wheat they only grew potatoes.Their food became monotone and they got ill. So I thought how about changing it that if you eat pork meat multiple times it reduces the amount of food it adds on the foodbar. This woud make the new argiculture (and I hope butchering comes in to) mutch more... awesome. :)

Sounds cool
0

Share this post


Link to post
Share on other sites

I like the idea as long as this corresponds to all foods not just pork but I will assume that was just an example.

0

Share this post


Link to post
Share on other sites

I like the idea as long as this corresponds to all foods not just pork but I will assume that was just an example.

yeah only pork would be foolish xD

0

Share this post


Link to post
Share on other sites

So, let's say...

  • The game should store how much food items a player has eaten.
  • A sum of the total items is stored, too. So that it can be known what percent of your diet is each food item.
  • Each time you eat a food item, it's checked how much percent of your diet is that item:

  • less than 25%: extra half food marker. Placebo effect due to an exotic food, I suppose...
  • between 25% and 50%: normal effect.
  • between 50% and 75%: the food replenishes a quarter less food markers than normal.
  • more than 75%: the food replenishes half as food markers than normal.
...hmmm, careful, the food items list can get big fast, and this data structure with it, too.

But it looks like a good idea, though. You should have some feedback, as if the player where thinking "oooh, bacon again? damm!"; no clear idea of how to do this, anyway...

0

Share this post


Link to post
Share on other sites

Instead of using the hunger bar since that's what is used to determine whether or not you're actually hungry, why not use a separate data structure. Make a list of everything eaten as it's eaten. Duplicates don't add an additional entry so you just perform a quick search through the list to see IF it's been eaten and just reset its timer. Anything in the struct that hasn't been eaten in say 18 hours is removed. I'm not sure how many edible foods there will be in the end but I don't see it being a resource hog unless there's an enormous variety of foods. Could also look at actually eating a balanced diet. Maybe create a class that is a percentage of everything you've eaten - it starts out empty and eventually the "empty" portions of the structure/class are overridden with the food IDs untill you have, essentially, a pie chart of your diet. Once a single ID hits like you said 75%, it doesn't replenish your hunger bar as much (or even at all if you want to make it more difficult). Now, for error checking, you'd use what I mentioned a moment ago: null space so that the first food item you eat doesn't instantly set your diet percentage to 100%.

I'm sure I could iron out some prototype code if I had time but I've got other things to work on atm.

0

Share this post


Link to post
Share on other sites

So, let's say...

  • The game should store how much food items a player has eaten.
  • A sum of the total items is stored, too. So that it can be known what percent of your diet is each food item.
  • Each time you eat a food item, it's checked how much percent of your diet is that item:

  • less than 25%: extra half food marker. Placebo effect due to an exotic food, I suppose...
  • between 25% and 50%: normal effect.
  • between 50% and 75%: the food replenishes a quarter less food markers than normal.
  • more than 75%: the food replenishes half as food markers than normal.
...hmmm, careful, the food items list can get big fast, and this data structure with it, too.

But it looks like a good idea, though. You should have some feedback, as if the player where thinking "oooh, bacon again? damm!"; no clear idea of how to do this, anyway...

Or it could be an array filled with the last 10 items you've eaten, and it checks to see how much of each one is in the list before appropriating hunger points.

If you're starving it shouldn't matter though.

How about, instead of this, we have certain "dietary requirements" you need to meet. Otherwise you'll be less healthy, and if enough time passes (and you are still missing essential calories/proteins), then you get some sort of debuff like -10% mining speed, or -25% sprint speed, even at full food bar. The debuff would also tell you what you're missing out on, whether it's meat proteins, milk proteins, wheat, sugar, whatever. This wouldn't work without a whole bunch of new foods though. Being able to cook sugar down into caramel and make candy in game would be fun :P (The Aether mod had gingerbread men and swet candies!).

0

Share this post


Link to post
Share on other sites

Or it could be an array filled with the last 10 items you've eaten, and it checks to see how much of each one is in the list before appropriating hunger points.

If you're starving it shouldn't matter though.

How about, instead of this, we have certain "dietary requirements" you need to meet. Otherwise you'll be less healthy, and if enough time passes (and you are still missing essential calories/proteins), then you get some sort of debuff like -10% mining speed, or -25% sprint speed, even at full food bar. The debuff would also tell you what you're missing out on, whether it's meat proteins, milk proteins, wheat, sugar, whatever. This wouldn't work without a whole bunch of new foods though. Being able to cook sugar down into caramel and make candy in game would be fun :P (The Aether mod had gingerbread men and swet candies!).

10 feels like too little, but I like where your idea is going. Maybe we could simplify by grouping the thing into "vitamins", "proteins", "fat", "carbohidrates", "water", "fibre", and give each one of those a bonus and a penalty. Too little of the thing, you endure the penalty, enough of the thing, you get the bonus. Then it's easy to give one or more groups to each food item.

( Hell, if they feel crazy, they can give an integer value for each category for each food item, as in "the content of this bread is 50 carbohidrate units, 10 fibre units"; then each certain time, those numbers are decreased. Even, why not each time a player does something, a small amount of those are "burned" away... ok, this is starting to look scarily close to my diet plan :P )

0

Share this post


Link to post
Share on other sites

So, let's say...

  • The game should store how much food items a player has eaten.
  • A sum of the total items is stored, too. So that it can be known what percent of your diet is each food item.
  • Each time you eat a food item, it's checked how much percent of your diet is that item:

  • less than 25%: extra half food marker. Placebo effect due to an exotic food, I suppose...
  • between 25% and 50%: normal effect.
  • between 50% and 75%: the food replenishes a quarter less food markers than normal.
  • more than 75%: the food replenishes half as food markers than normal.
...hmmm, careful, the food items list can get big fast, and this data structure with it, too.

But it looks like a good idea, though. You should have some feedback, as if the player where thinking "oooh, bacon again? damm!"; no clear idea of how to do this, anyway...

Well, you can put the food list in a .txt, those types of files don't take up that much of room on your harddisk, and it could be recalculated everytime you eat something. A computer shouldn't have any problems with that, because it practically is just a very powerful calculator.

0

Share this post


Link to post
Share on other sites

That method is acutally slower (not sure on the details) but it's because the computer has to parse a file and then with what you're saying, it would read and write it constantly (which is slower as well). It is actually much more efficient if that text file were used as a part of the world save instead. Computers work a lot faster with data loaded into RAM and the calculations done there. Read/write processes are slower because the harddrive/disk is a physical machine that has to move the disks into position to read and write data before it can actually read and write. When the data is loaded into RAM, it's all electronic and there's no physical movement (flash drives are essentially the exception to this).

0

Share this post


Link to post
Share on other sites

A .txt file with several thousand words is still less than 400kb. I don't see why anyone is complaining about memory usage O.o

10 feels like too little, but I like where your idea is going. Maybe we could simplify by grouping the thing into "vitamins", "proteins", "fat", "carbohidrates", "water", "fibre", and give each one of those a bonus and a penalty. Too little of the thing, you endure the penalty, enough of the thing, you get the bonus. Then it's easy to give one or more groups to each food item.

( Hell, if they feel crazy, they can give an integer value for each category for each food item, as in "the content of this bread is 50 carbohidrate units, 10 fibre units"; then each certain time, those numbers are decreased. Even, why not each time a player does something, a small amount of those are "burned" away... ok, this is starting to look scarily close to my diet plan :P )

Yarr, you have been infected with scurvy, mate.

0

Share this post


Link to post
Share on other sites

It's not about HDD space, it's about excessive HDD read/write calls which are very slow when compared to just doing it all in memory (RAM). Basicly it would be best to just add it all in as code so we don't have MC dynamically accessing a text file to reference the foods and nutrients you've consumed.

0

Share this post


Link to post
Share on other sites

Some interesting ideas here. Remember that as the system becomes more challenging, it also needs to be rewarding, otherwise it becomes a nuisance and just more tedium that does not equal fun. I like where this is going however. Continue throwing around ideas and I'll be checking back here later.

0

Share this post


Link to post
Share on other sites

When I posted I more though of a simple system. So you could not survive on a big wheat field, that you would need a barn. But the nutrition is also nice, it would ask for big plates like:

You use a bowl and add potatoes, meat and some lettuce or so :D wich gives you a big meal that lasts for a long time and gives a lot of nutrition.

0

Share this post


Link to post
Share on other sites
Sign in to follow this  
Followers 0