62 float fremaining_lifetime =
m_Player.GetLifetime();
67 if (FeatureTimeAccel.GetFeatureTimeAccelEnabled(ETimeAccelCategories.FOOD_DECAY))
69 timeAccel = FeatureTimeAccel.GetFeatureTimeAccelValue();
70 float percetElapsed = 1-fdecay_percentage;
71 fdecay_percentage =
Math.
Clamp(1 - percetElapsed * timeAccel,0,1);
int m_iTriesToGetLifetime
void CorpseData(notnull PlayerBase player, int time_of_death)
void UpdateCorpseState(bool force_check=false)
const int GET_LIFETIME_TRIES_MAX
static const float CORPSE_THRESHOLD_MEDIUM
static const int CORPSE_STATE_FRESH
static const int CORPSE_STATE_DECAYED
static const float CORPSE_THRESHOLD_DECAYED
static const int CORPSE_STATE_MEDIUM
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.