DayZ 1.28
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 строка 835

836 {
837 if (m_Stamina <= 0)
838 {
839 m_StaminaDepleted = true;
841 if (!m_IsInCooldown)
842 {
843 // set this only once
844 SetCooldown(GameConstants.STAMINA_REGEN_COOLDOWN_EXHAUSTION);
845 }
846 }
847 else
848 {
849 m_StaminaDepleted = false;
850 }
851 }
bool m_StaminaDepleted
DEPRECATED.
Определения StaminaHandler.c:277
float m_Stamina
Определения StaminaHandler.c:264
void SetCooldown(float time, int modifier=-1)
set cooldown timer between each consume of stamina
Определения StaminaHandler.c:854
bool m_IsInCooldown
Определения StaminaHandler.c:286

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

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