Changes

Jump to navigation Jump to search
520 bytes added ,  09:57, 21 February 2022
Made sleep section clearer
Line 19: Line 19:     
==Sleeping==
 
==Sleeping==
Sleeping restores the player's initial energy level for the next day. Going to bed at or before 12:00AM normally restores energy to its maximum. If the player goes to sleep exhausted (or passes out), sleep removes the exhaustion, but energy restoration is reduced to 50%.
+
Sleeping restores the player's initial energy level for the next day. Going to bed at or before 12:00AM normally restores energy to its maximum. However, if the player goes to bed late, passes out, or is exhausted, the amount of energy regained is reduced.
   −
Energy restoration is also reduced if the player goes to bed after 12:00AM. The reduction is 2.5% per 10 minutes up until 01:00AM. After 01:00AM, it is 25% plus another 2.5% per 10 additional minutes. The player passes out at 02:00AM. For example, after retiring at 12:10AM, the player awakens with 97.5% of maximum energy. After retiring exhausted at 1:50AM, the player awakens with 12.5% of maximum energy.
+
If the player goes to sleep exhausted, sleep removes the exhaustion, but energy restoration is reduced by 50%.
   −
If the new day's calculated initial energy level is lower than the player's actual energy level at the time they went to sleep, the player's energy level is left unchanged and not reduced.
+
Energy restoration is also reduced if the player goes to bed after 12:00AM. This reduction stacks additively with the exhausted penalty.
   −
==Leveling Up==
+
The amount of energy reduction has been calculated in the below table.<ref name="sleep_calculation"/>
 +
 
 +
{| class="wikitable"
 +
|+ Late to Bed Penalty
 +
|-
 +
! Time !! Energy Loss
 +
|-
 +
| 12:10AM || -2.5%
 +
|-
 +
| 12:20AM || -5%
 +
|-
 +
| 12:30AM || -7.5%
 +
|-
 +
| 12:40AM || -10%
 +
|-
 +
| 12:50AM || -12.5%
 +
|-
 +
| 1:00AM || -25%
 +
|-
 +
| 1:10AM || -27.5%
 +
|-
 +
| 1:20AM || -30%
 +
|-
 +
| 1:30AM || -32.5%
 +
|-
 +
| 1:40AM || -35%
 +
|-
 +
| 1:50AM || -37.5
 +
|-
 +
| 2:00AM || -50%
 +
|}
 +
 
 +
If the new day's calculated initial energy level is lower than the player's actual energy level at the time they went to sleep, the player's energy level is left unchanged and not reduced, unless they are exhausted.
 +
 
 +
A player cannot start a day with less than 1 energy.
 +
 
 +
===Leveling Up===
 
The morning after a skill is leveled up (or after changing professions with at the [[The Sewers#Statue Of Uncertainty|Statue Of Uncertainty]]), the player awakens with 100% of maximum energy, regardless of the sleep or exhaustion calculation.
 
The morning after a skill is leveled up (or after changing professions with at the [[The Sewers#Statue Of Uncertainty|Statue Of Uncertainty]]), the player awakens with 100% of maximum energy, regardless of the sleep or exhaustion calculation.
   Line 60: Line 96:  
<references>
 
<references>
 
<ref name="daily_kiss">The effects of the first kiss in a day are handled in <samp>NPC::checkAction</samp>, specifically in <samp>if (!this.hasBeenKissedToday.Value)</samp>.</ref>
 
<ref name="daily_kiss">The effects of the first kiss in a day are handled in <samp>NPC::checkAction</samp>, specifically in <samp>if (!this.hasBeenKissedToday.Value)</samp>.</ref>
 +
<ref name="sleep_calculation">Energy amounts for the next day are calculated in <samp>Farmer::dayupdate</samp>, specifically starting at <samp>oldStamina = this.Stamina</samp>.</ref>
 
<ref name="swimming">The effects of the [[Spa]]/swimming are handled in <samp>Farmer::updateCommon</samp>, specifically in <samp>if (this.swimming)</samp>. It Checks whether the player has not moved in 800ms and at least 100ms has passed and increases health and energy by 1.</ref>
 
<ref name="swimming">The effects of the [[Spa]]/swimming are handled in <samp>Farmer::updateCommon</samp>, specifically in <samp>if (this.swimming)</samp>. It Checks whether the player has not moved in 800ms and at least 100ms has passed and increases health and energy by 1.</ref>
 
<ref name="multiplayer_bed">The effects of a multiplayer bed are handled in <samp>Farmer::Update</samp>, specifically in <samp>if (this.isInBed && Game1.IsMultiplayer && Game1.shouldTimePass(false))</samp>. It Checks whether at least 500ms has passed and increases health and energy by 1.</ref>
 
<ref name="multiplayer_bed">The effects of a multiplayer bed are handled in <samp>Farmer::Update</samp>, specifically in <samp>if (this.isInBed && Game1.IsMultiplayer && Game1.shouldTimePass(false))</samp>. It Checks whether at least 500ms has passed and increases health and energy by 1.</ref>

Navigation menu