DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ CheckStaminaState()

void StaminaHandler::CheckStaminaState ( )
inlineprotected

check if the stamina is completely depleted

in case of complete depletion - start a cooldown timer before the regeneration cycle start

См. определение в файле StaminaHandler.c строка 1015

1016 {
1017 if (m_Stamina <= 0)
1018 {
1019 m_StaminaDepleted = true;
1021 if (!m_IsInCooldown)
1022 {
1023 // set this only once
1024 SetCooldown(GameConstants.STAMINA_REGEN_COOLDOWN_EXHAUSTION);
1025 }
1026 }
1027 else
1028 {
1029 m_StaminaDepleted = false;
1030 }
1031 }
bool m_StaminaDepleted
Определения StaminaHandler.c:287
float m_Stamina
Определения StaminaHandler.c:272
void SetCooldown(float time, int modifier=-1)
set cooldown timer between each consume of stamina
Определения StaminaHandler.c:1034
bool m_IsInCooldown
Определения StaminaHandler.c:295

Перекрестные ссылки m_IsInCooldown, m_Stamina, m_StaminaDepleted, SetCooldown() и GameConstants::STAMINA_REGEN_COOLDOWN_EXHAUSTION.

Используется в Update().