Dayz Explorer  1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
waterbottle.c
Go to the documentation of this file.
1 class WaterBottle extends Bottle_Base
2 {
3  void WaterBottle()
4  {
5 
6  }
7 
8  void ~WaterBottle()
9  {
10 
11  }
12 
13  override bool IsContainer()
14  {
15  return true;
16  }
17 
18  override string GetPouringSoundset()
19  {
20  return "emptyVessle_WaterBottle_SoundSet";
21  }
22 
23  override string GetEmptyingLoopSoundsetHard()
24  {
25  return "pour_HardGround_WatterBottle_SoundSet";
26  }
27 
28  override string GetEmptyingLoopSoundsetSoft()
29  {
30  return "pour_SoftGround_WatterBottle_SoundSet";
31  }
32 
33  override string GetEmptyingLoopSoundsetWater()
34  {
35  return "pour_Water_WatterBottle_SoundSet";
36  }
37 
38  override string GetEmptyingEndSoundsetHard()
39  {
40  return "pour_End_HardGround_WatterBottle_SoundSet";
41  }
42 
43  override string GetEmptyingEndSoundsetSoft()
44  {
45  return "pour_End_SoftGround_WatterBottle_SoundSet";
46  }
47 
48  override string GetEmptyingEndSoundsetWater()
49  {
50  return "pour_End_Water_WatterBottle_SoundSet";
51  }
52 
53  override bool CanPutInCargo( EntityAI parent )
54  {
55  if( !super.CanPutInCargo(parent) ) {return false;}
56  if ( parent && (parent.IsKindOf("WatterBottle"))/* && !(parent.IsKindOf("Container_Base"))*/)
57  {
58  return false;
59  }
60 
61  return true;
62  }
63 
64  override bool IsOpen()
65  {
66  return true;
67  }
68 
69  override void EEOnCECreate()
70  {
71  super.EEOnCECreate();
72 
73  int rand = Math.RandomInt(0, 10);
74  if (rand > 5)
75  {
76  InsertAgent(eAgents.CHOLERA, 1);
77  }
78  }
79 }
GetEmptyingLoopSoundsetWater
string GetEmptyingLoopSoundsetWater()
EEOnCECreate
override void EEOnCECreate()
Definition: fireworksbase.c:23
IsOpen
override bool IsOpen()
Definition: fireplacebase.c:2395
Bottle_Base
Definition: canistergasoline.c:1
InsertAgent
override void InsertAgent(int agent, float count=1)
Definition: itembase.c:3860
GetPouringSoundset
string GetPouringSoundset()
eAgents
eAgents
Definition: eagents.c:2
CanPutInCargo
override bool CanPutInCargo(EntityAI parent)
Definition: explosivesbase.c:247
GetEmptyingEndSoundsetWater
string GetEmptyingEndSoundsetWater()
GetEmptyingLoopSoundsetHard
string GetEmptyingLoopSoundsetHard()
GetEmptyingEndSoundsetHard
string GetEmptyingEndSoundsetHard()
GetEmptyingEndSoundsetSoft
string GetEmptyingEndSoundsetSoft()
Math
Definition: enmath.c:6
EntityAI
Definition: building.c:5
GetEmptyingLoopSoundsetSoft
string GetEmptyingLoopSoundsetSoft()