Dayz Explorer  1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
bandagedressing.c
Go to the documentation of this file.
1 class BandageDressing extends ItemBase
2 {
3  //================================================================
4  // IGNITION ACTION
5  //================================================================
6  override bool HasFlammableMaterial()
7  {
8  return true;
9  }
10 
11  override bool CanBeIgnitedBy( EntityAI igniter = NULL )
12  {
13  if ( GetHierarchyParent() ) return false;
14 
15  return true;
16  }
17 
18  override bool CanIgniteItem( EntityAI ignite_target = NULL )
19  {
20  return false;
21  }
22 
23  override void OnIgnitedTarget( EntityAI ignited_item )
24  {
25  }
26 
27  override void OnIgnitedThis( EntityAI fire_source )
28  {
29  Fireplace.IgniteEntityAsFireplace( this, fire_source );
30  }
31 
32  override bool IsThisIgnitionSuccessful( EntityAI item_source = NULL )
33  {
34  return Fireplace.CanIgniteEntityAsFireplace( this );
35  }
36 
37  override void SetActions()
38  {
39  super.SetActions();
40 
47  }
48 
49  override float GetBandagingEffectivity()
50  {
51  return 2.0;
52  };
53 
54  override bool CanBeDisinfected()
55  {
56  return true;
57  }
58 
59  override float GetInfectionChance(int system = 0, Param param = null)
60  {
61  if(m_Cleanness == 1)
62  {
63  return 0;
64  }
65  else
66  {
67  return 0.05;
68  }
69  }
70 
71  override void OnCombine(ItemBase other_item)
72  {
73  super.OnCombine(other_item);
74  if (m_Cleanness == 1 && other_item.m_Cleanness == 0)
75  SetCleanness(0);
76  }
77 }
ItemBase
Definition: inventoryitem.c:730
OnIgnitedThis
override void OnIgnitedThis(EntityAI fire_source)
Executed on Server when some item ignited this one.
Definition: fireworksbase.c:96
Param
Base Param Class with no parameters. Used as general purpose parameter overloaded with Param1 to Para...
Definition: param.c:11
CanBeDisinfected
bool CanBeDisinfected()
Definition: itembase.c:3097
ActionDetach
void ActionDetach()
Definition: actiondetach.c:10
m_Cleanness
int m_Cleanness
Definition: itembase.c:36
SetCleanness
void SetCleanness(int value, bool allow_client=false)
Definition: itembase.c:3678
ActionBandageSelf
ActionBandageSelfCB ActionContinuousBaseCB ActionBandageSelf()
Definition: actionbandageself.c:17
HasFlammableMaterial
override bool HasFlammableMaterial()
Definition: fireworksbase.c:41
AddAction
void AddAction(typename actionName)
Definition: advancedcommunication.c:86
SetActions
void SetActions()
Definition: advancedcommunication.c:79
ActionCreateIndoorFireplace
Definition: actioncreateindoorfireplace.c:1
ActionCreateIndoorOven
Definition: actioncreateindooroven.c:1
OnCombine
void OnCombine(ItemBase other_item)
Definition: itembase.c:2084
ActionAttach
ActionAttachWheels ActionAttach
GetInfectionChance
float GetInfectionChance(int system=0, Param param=null)
Infection chance while/after using this item, originally used for wound infection after bandaging,...
Definition: itembase.c:656
ActionBandageTarget
ActionBurnSewSelfCB ActionBandageTarget
GetBandagingEffectivity
float GetBandagingEffectivity()
Definition: itembase.c:4409
CanBeIgnitedBy
override protected bool CanBeIgnitedBy(EntityAI igniter=NULL)
Definition: fireworksbase.c:102
EntityAI
Definition: building.c:5