No problem. I'll consider it, but my main priority is getting world gen some adequate article coverage, and secondarily cleaning up some bad info. The guides are probably the worst culprits in that department.
Read this post of yours and wanted to ask you if it's DST only because I'm pretty sure that his hunger drain stays 3x through mighty form. Also are you sure about the speed bonus? Can you tell me where in the files did you find this because I've been searching for months in the wrong places it seems.
It's in Wolfgang's prefab (scripts/prefabs/wolfgang.lua), the applymightiness function (this runs on every "hungerdelta" event, or change in hunger). You can see that the hunger_rate has the same "easing" (scaling) applied to it that the health, damage, and scale do.
I just checked his prefab for DST, RoG, and Vanilla, and that part of the code, at least, is identical.
Huh, I guess I never noticed it due to the overall change being minimal. Did a small test though and indeed it took him longer to go to normal than it should with the constant 3x, but I don't think it goes lower than 2.20x until normal. And in your recent edit you say it goes as low as 1.5.
So can you help me pull out the actual values? Especially the ones when Wimpy and the actual speed bonus.
So taking his applymightiness code and replacing the values, his defaults (normal form) are:
local damage_mult = 1
local hunger_rate = 1.5
local health_max = 200
local scale = 1
For mighty and wimpy, it does an "easing" (from scripts/easing.lua):
local function linear(t, b, c, d)
return c * t / d + b
end
Easing is a little confusing in this context, but it helps to look at it in terms of the context it was written for, for a time-dependent value that begins at value b, changes a total of c (so the maximum value is b + c), over a duration of d, where t is the current time. In the context of Wolfgang, time isn't involved, so d (duration) is always 1, and t (time) uses the "mightiness percent". In Wolfgang's files, since they're more concerned with the minimum and maximum values in the easing, they provide a minimum value to b, and provide max - min to c.
So for mighty form:
local mighty_percent = -- the percent progress from the start of mighty form to the end, in hunger
damage_mult = easing.linear(mighty_percent, 1.25, 2 - 1.25, 1)
health_max = easing.linear(mighty_percent, 200, 300 - 200, 1)
hunger_rate = easing.linear(mighty_percent, 1.5, 3 - 1.5, 1)
scale = easing.linear(mighty_percent, 1, 1.25 - 1, 1)
And wimpy form:
local wimpy_percent = -- the percent progress from the start of wimpy form to the end, in hunger
damage_mult = easing.linear(wimpy_percent, 0.5, 0.75 - 0.5, 1)
health_max = easing.linear(wimpy_percent, 150, 200 - 150, 1)
hunger_rate = easing.linear(wimpy_percent, 1, 1.5 - 1, 1)
scale = easing.linear(wimpy_percent, 0.9, 1 - 0.9, 1)
Well I'm getting damage_mult = 100 for full mighty so is it 100% added to the base damage? Is that how it works, because I can't seem to make sense of the other results...
Also how do you understand the speed bust at 300 is 25% and not some other value?
One final concern, I tried to let Wolfgang starve completely from 300-0 and it took him a little more than 2 days and half. Shouldn't that be a lot more than two days the way his hunger apparently scales.
No, percents are in the form of 0.5, not 50. So... full mighty is a mighty_percent of 1, easing.linear(1, 1.25, 2 - 1.25, 1) = 0.75*1/1 + 1.25 = 2
His speed boost is 25% at 300 because his scale is 1.25.
As for how long it takes him to starve... that's actually not an easy thing to answer theoretically. You could calculate it with a continuous analysis, but the game is technically doing numerical steps every sim tick... which I believe is 30/s?
With a simple Lua program, I simulated 2.63 days, which matches what you said. The scaling hunger rate really works against him-- if you give him a flat hunger rate of 3 for mighty, 1.5 for normal, and 1 for wimpy, he lasts ~0.36 days in mighty, ~1.07 days in normal, and ~1.3 days in wimpy, for a total of ~2.76 days (I added without the rounding error). The naive assumption would be that you can do it in 3 chunks with the average hunger rate over that chunk (2.25 for mighty, 1.5 for normal, 1.25 for wimpy), you get 2.61, but you actually need to do a harmonic mean here because we're dealing with rates, which gives you a rate of 2 for mighty and 1.2 for wimpy, or 2.71 days. But... because the game is doing an numerical approximation, it's a little off. You can think of the hunger rate like a curve going down, and the game is doing a rectangular reimann sum of the curve, so because the curve is going down, the reimann sums overestimate the amount of hunger drained (since it's using the rate at the start of each step as the rate for the entire step).
Hello , thanks for your edit to the File:Birchnut.png page. We hope you will continue contributing constructively!
Wait, I forget to tell you...
Always make sure your additions are factual, not subjective, and don't contain instructional language or speculation. If in doubt, just ask!
Keep strategy and tip sections to the minimum and help us rewrite excessively long ones. We have a Guides page for comprehensive instructions instead.
Don't upload images randomly. If you want to improve the current version, please upload a new version of the image, instead of uploading another image with different name.
Don't use second person pronouns ("you", "your", etc.), instead use third person ("the player", singular "they", etc.) and help us write neutral articles without them.
Please leave a message on my talk page if I can help with anything. Thanks! Anemicne (talk) 20:03, March 14, 2014 (UTC)