PDA

View Full Version : (Question from Devs) Barley Seeds



Citan
05-23-2017, 04:22 PM
Hey guys, a question for anyone that's grown barley in the currently-live update. Basically I need to know if the seed calculations are working right. When you grow barley, there should be a 70% chance to get more seeds, and if you do get more seeds, you'll get 0, 1, or 2 (equal chances for each). So after you do a stack of barley, you should have only 70% of the number of seeds you had before. Is that how it's working for you?

(The design is trying to make it easier to grow a lot of barley, but still make seeds found in the wilds or on monsters a little valuable.)

Niph
05-24-2017, 11:49 AM
I just made a little experiment to verify that.

Setup: my main character (Niph, gardening 72) growing Barley only at Yvin's farm (to stay away from musicians). No music or gardening buffs whatsoever.

Planted 40 seeds, two at a time, and upon harvesting:
. Got zero seed = 26
. Got one seed = 14
. Got two seeds = 0

I think we can conclude that this is not what you intended.

I reached 73 in gardening during this but observed no difference.

Since I was growing two barley seeds at a time, I also recorded what happened during each batch. Interestingly, there seems to be a strong correlation between planted seeds and recovery:
Got 0-0 = 6
Got 1-0 or 0-1 = 14 (unfortunately I did not record the order)
Got 1-1 = 0

The odds of not getting at least one batch with a seed from each barley is abysmally small, so I believe barley seed recovery depends on something more than just luck.

I'm now on the next step, growing Barley one at a time, but under the influence of Vodka this time!

Crissa
05-24-2017, 12:23 PM
Wait, what are you getting if you're not getting seeds? O-o What humans eat from barley is the seed.

Niph
05-24-2017, 12:48 PM
Update: growing one at a time, I recovered 11 seeds out of 32.

Recalculating probabilities, it seems that the chance for recovery could be 35%. If that's so, the odds of not getting a 1-1 recovery from a batch of two is 7.3%, so not so abysmally small than I thought at first.

I suspect it could be a simple mistake. In your code, do you have something like recovered_seeds = rand() mod 2. If that's so, should be rand() mod 3, a classic!

ShieldBreaker
05-24-2017, 01:10 PM
Wait, what are you getting if you're not getting seeds? O-o What humans eat from barley is the seed.

this is correct, but for the sake of game abstraction, maybe we can just think about it as the brewing barley is complete heads of barley seeds ready for threshing, and the other barley seeds are loose barley seeds that for your own reason you decided are now only good for planting. Brewer want complete heads of barley for what ever in-game reason makes the most sense. Maybe seeds seem fit for planting but not consumption or sale. Or seeds are from exceptional plants that produced more then usual, so you would want to gather a bit of that and set it aside for later planting. To help with the role playing it could be explained in each items text.

Crissa
05-24-2017, 03:48 PM
That's just confusing x-x

Citan
05-25-2017, 02:26 AM
Niph - thanks for testing it out! I think I see the problem -- it's weighting the seed stack size wrong, so it's coming out basically 0, 0, or 1. Not quite an off-by-one error, but something similar. Will fix it in the next snapshot!

Crissa - you get two kinds of seeds from growing barley, basically: plantable and edible. It's the simplest way to get the game mechanics to work out.