Dayz Explorer  1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
wet.c
Go to the documentation of this file.
2 {
3  override void Init()
4  {
5  m_TrackActivatedTime = false;
6  m_ID = eModifiers.MDF_WETNESS;
9  }
10  override bool ActivateCondition(PlayerBase player)
11  {
12  if (player.GetStatWet().Get() == player.GetStatWet().GetMax())
13  return true;
14 
15  return false;
16  }
17 
18  override bool DeactivateCondition(PlayerBase player)
19  {
20  if (player.GetStatWet().Get() == player.GetStatWet().GetMin())
21  return true;
22 
23  return false;
24  }
25 
26 
27  override void OnActivate(PlayerBase player)
28  {
29  if( player.m_NotifiersManager ) player.m_NotifiersManager.ActivateByType(eNotifiers.NTF_WETNESS);
30  }
31 
32  override void OnReconnect(PlayerBase player)
33  {
34  this.OnActivate(player);
35  }
36 
37 
38  override void OnDeactivate(PlayerBase player)
39  {
40  if( player.m_NotifiersManager ) player.m_NotifiersManager.DeactivateByType(eNotifiers.NTF_WETNESS);
41  }
42 
43  override string GetDebugText()
44  {
45  string wetness = m_Player.GetStatWet().Get().ToString();
46  string wetness_min = m_Player.GetStatWet().GetMin().ToString();
47  return "wetness:"+wetness+" | " +"wetness min:"+wetness_min;
48  }
49 
50  override string GetDebugTextSimple()
51  {
52  return "";
53  }
54 };
m_TickIntervalActive
float m_TickIntervalActive
Definition: modifierbase.c:19
m_TrackActivatedTime
bool m_TrackActivatedTime
Definition: modifierbase.c:15
DEFAULT_TICK_TIME_ACTIVE
const int DEFAULT_TICK_TIME_ACTIVE
Definition: modifiersmanager.c:31
PlayerBase
Definition: playerbaseclient.c:1
m_Player
DayZPlayer m_Player
Definition: hand_events.c:42
m_TickIntervalInactive
float m_TickIntervalInactive
Definition: modifierbase.c:18
eModifiers
eModifiers
Definition: emodifiers.c:1
ModifierBase
Definition: breathvapourmdfr.c:3
eNotifiers
eNotifiers
Definition: notifiersmanager.c:1
m_ID
protected int m_ID
ID of effect, given by SEffectManager when registered (automatically done when playing through it)
Definition: effect.c:49
WetMdfr
Definition: wet.c:1
DEFAULT_TICK_TIME_INACTIVE
const int DEFAULT_TICK_TIME_INACTIVE
Definition: modifiersmanager.c:33