Dwarf Fortress Bug Tracker - Dwarf Fortress
View Issue Details
0010604Dwarf FortressAdventure Mode -- Eating/Drinkingpublic2018-03-09 01:292018-08-04 22:56
0010604: Alcohol uses incorrect DWF_STRETCH, adventure mode effects take much longer relative to fort-mode effects
The syndrome for inebriation makes limited use of DWF_STRETCH in an attempt to make the effect more acute in adventure mode, acknowledging the way syndromes behave in adventure mode relative to fort mode.

However, this time scaling is inaccurate. The reason is that there are effectively 72 adventure-mode ticks for every 1 fortress-mode tick. Syndrome tokens start, peak, end) are accurate within fort-mode time scale.

For example. If it says a symdrome takes 10 ticks to start, a single press of the wait key in fort-time will begin the effect. But in adventure-mode time scaling, that 10 syndrome length will require at least 720 ticks, or 72 presses of the wait key. More often the player has to wait a few additional keypresses beyond that. Given even a start duration of 0 (without the inclusion of abrupt) requires a good few keypresses before effects become visible, I'd assume this to be the source of the extra time.
1. Drink booze in adventure mode, preferably 2 units as a human to ensure visible symptoms.
2. Wait for effects to occur. Dizziness is expected at or around 780 ticks, which should be 78 presses of the wait key (default bind is period key).
3. Observe that dizziness does not occur within the expected period (pun intended) of time.
4. Feel free to count how many times you had to press wait. I'd reasonably expect it to be well over 5000.
I propose a solution that uses a DWF_STRETCH that's closer to the 1:72 ratio. Here's one example I now intend to use in my own modding projects:


This uses a 1:80 ratio instead. The reason for this is because almost all of the numbers used in the syndrome entry are divisible by 80. This ensures that scaling it up to fortress-mode time still gets almost identical behavior.

The only exceptions were a few instances where the start time was less than 80. Given 80 ticks is still lightning-fast in fortress mode, it seems acceptable.

In return however, the symptoms take effect at a rate comparable to what you'd expect in fortress mode. Since the multiplier used is a bit larger than 72 this does mean the effects are slightly more acute relative to fortress mode. I say slightly of course. An example is that the total duration of drunkenness is 480 presses of the wait key in fort-mode time scaling, versus an EXPECTED total duration of 432 presses of the wait key.
adventure mode, alcohol, syndrome, time
Issue History
2018-03-09 01:29chaosvoltNew Issue
2018-03-09 01:30chaosvoltTag Attached: adventure mode
2018-03-09 01:30chaosvoltTag Attached: alcohol
2018-03-09 01:30chaosvoltTag Attached: syndrome
2018-03-09 01:30chaosvoltTag Attached: time
2018-05-25 14:01chaosvoltNote Added: 0038380
2018-08-04 22:56a52Note Added: 0038678
2018-08-04 23:17a52Note Edited: 0038678bug_revision_view_page.php?bugnote_id=0038678#r15722

2018-05-25 14:01   
Related, venom in general does not do this either, making them all rather laughable in adventure mode. Problem there is a lot of syndromes in the raws have timing that does not scale down by 72 or 80 as well.
2018-08-04 22:56   
(edited on: 2018-08-04 23:17)
Related issue: 0010432