DayZ Scripts
v1.21.156300 ยท Jun 20, 2023
Loading...
Searching...
No Matches
RockBase.c
Go to the documentation of this file.
1
class
RockBase
:
Object
2
{
3
override
bool
IsRock
()
4
{
5
return
true
;
6
}
7
8
override
bool
CanBeAutoDeleted
()
9
{
10
return
false
;
11
}
12
13
int
GetAmountOfDrops
(
ItemBase
item)
14
{
15
if
(item)
16
{
17
switch
(item.GetType())
18
{
19
case
"Pickaxe"
:
20
return
4;
21
case
"SledgeHammer"
:
22
return
8;
23
}
24
}
25
26
return
1;
27
}
28
29
/* Defines the yield of the action*/
30
void
GetMaterialAndQuantityMap
(
ItemBase
item, out
map<string,int>
output_map)
31
{
32
if
(item == null)
33
{
34
return
;
35
}
36
37
switch
(item.GetType())
38
{
39
case
"Pickaxe"
:
40
case
"SledgeHammer"
:
41
case
"Hammer"
:
42
case
"Mace"
:
43
output_map.Insert(
"Stone"
,1);
44
break
;
45
case
"PipeWrench"
:
46
case
"Wrench"
:
47
case
"Screwdriver"
:
48
case
"Crowbar"
:
49
case
"MeatTenderizer"
:
50
output_map.Insert(
"SmallStone"
,1);
51
break
;
52
}
53
}
54
55
/*Return value defines how much damage the item will take*/
56
float
GetDamageToMiningItemEachDrop
(
ItemBase
item)
57
{
58
if
(item)
59
{
60
switch
(item.GetType())
61
{
62
case
"SledgeHammer"
:
63
case
"Pickaxe"
:
64
return
20;
65
case
"Wrench"
:
66
case
"Screwdriver"
:
67
case
"MeatTenderizer"
:
68
return
25;
69
case
"PipeWrench"
:
70
case
"Crowbar"
:
71
return
50;
72
case
"Hammer"
:
73
case
"Mace"
:
74
return
40;
75
}
76
}
77
78
return
25;
79
}
80
};
81
82
class
Static_stone1
:
RockBase
{};
83
class
Static_stone2
:
RockBase
{};
84
class
Static_stone3
:
RockBase
{};
85
class
Static_stone4
:
RockBase
{};
86
class
Static_stone5
:
RockBase
{};
87
class
Static_rock_apart1
:
RockBase
{};
88
class
Static_rock_apart2
:
RockBase
{};
89
class
Static_rock_bright_apart1
:
RockBase
{};
90
class
Static_rock_bright_apart2
:
RockBase
{};
91
class
Static_rock_bright_monolith1
:
RockBase
{};
92
class
Static_rock_bright_monolith2
:
RockBase
{};
93
class
Static_rock_bright_monolith3
:
RockBase
{};
94
class
Static_rock_bright_monolith4
:
RockBase
{};
95
class
Static_rock_bright_spike1
:
RockBase
{};
96
class
Static_rock_bright_spike2
:
RockBase
{};
97
class
Static_rock_bright_spike3
:
RockBase
{};
98
class
Static_rock_bright_wallh1
:
RockBase
{};
99
class
Static_rock_bright_wallh2
:
RockBase
{};
100
class
Static_rock_bright_wallh3
:
RockBase
{};
101
class
Static_rock_bright_wallv
:
RockBase
{};
102
class
Static_rock_monolith1
:
RockBase
{};
103
class
Static_rock_monolith2
:
RockBase
{};
104
class
Static_rock_monolith3
:
RockBase
{};
105
class
Static_rock_monolith4
:
RockBase
{};
106
class
Static_rock_spike1
:
RockBase
{};
107
class
Static_rock_spike2
:
RockBase
{};
108
class
Static_rock_spike3
:
RockBase
{};
109
class
Static_rock_wallh1
:
RockBase
{};
110
class
Static_rock_wallh2
:
RockBase
{};
111
class
Static_rock_wallh3
:
RockBase
{};
112
class
Static_rock_wallv
:
RockBase
{};
113
class
Static_rock_stone6
:
RockBase
{};
114
class
Static_rock_stone6_moss
:
RockBase
{};
115
class
Static_rock_stone7
:
RockBase
{};
116
class
Static_rock_stone7_moss
:
RockBase
{};
117
class
Static_rock_stone8
:
RockBase
{};
118
class
Static_rock_stone8_moss
:
RockBase
{};
119
class
Static_rock_stone9
:
RockBase
{};
120
class
Static_rock_stone9_moss
:
RockBase
{};
121
class
Static_rock_stone10
:
RockBase
{};
122
class
Static_rock_stone10_moss
:
RockBase
{};
123
// currently unused rocks
124
/*
125
126
class Static_stone5_Trail_B: RockBase {};
127
class Static_stone5_Trail_G: RockBase {};
128
class Static_stone5_Trail_R: RockBase {};
129
class Static_stone5_Trail_Y: RockBase {};
130
class Static_stones_erosion: RockBase {};
131
*/
132
133
134
//jtomasik - it would be blast being able just to inherit it from RockBase, but the way static objects are handled most likely don't allow it? ask p cimo
135
// obsolete
136
/*class Static_r2_boulder1: RockBase
137
{
138
};
139
class Static_r2_boulder2: RockBase
140
{
141
};
142
class Static_small_stone_01_f: RockBase
143
{
144
};
145
class Static_small_stone_02_f: RockBase
146
{
147
};
148
class Static_stone_small_f: RockBase
149
{
150
};
151
class Static_stone_small_w: RockBase
152
{
153
};
154
class Static_bluntstone_01: RockBase
155
{
156
};
157
class Static_bluntstone_01_lc: RockBase
158
{
159
};
160
class Static_bluntstone_02: RockBase
161
{
162
};
163
class Static_bluntstone_02_lc: RockBase
164
{
165
};
166
class Static_bluntstone_03: RockBase
167
{
168
};
169
class Static_SharpStone_01: RockBase
170
{
171
};
172
class Static_sharpstone_01_lc: RockBase
173
{
174
};
175
class Static_sharpstone_02: RockBase
176
{
177
};
178
class Static_sharpstone_02_lc: RockBase
179
{
180
};
181
class Static_sharpstone_03: RockBase
182
{
183
};
184
class Static_sharpstone_03_lc: RockBase
185
{
186
};*/
map
map
Definition
ControlsXboxNew.c:4
ItemBase
Definition
InventoryItem.c:732
Object
Definition
ObjectTyped.c:2
RockBase
Definition
RockBase.c:2
RockBase::GetDamageToMiningItemEachDrop
float GetDamageToMiningItemEachDrop(ItemBase item)
Definition
RockBase.c:56
RockBase::GetMaterialAndQuantityMap
void GetMaterialAndQuantityMap(ItemBase item, out map< string, int > output_map)
Definition
RockBase.c:30
RockBase::IsRock
override bool IsRock()
Definition
RockBase.c:3
RockBase::CanBeAutoDeleted
override bool CanBeAutoDeleted()
Definition
RockBase.c:8
RockBase::GetAmountOfDrops
int GetAmountOfDrops(ItemBase item)
Definition
RockBase.c:13
Static_rock_apart1
Definition
RockBase.c:87
Static_rock_apart2
Definition
RockBase.c:88
Static_rock_bright_apart1
Definition
RockBase.c:89
Static_rock_bright_apart2
Definition
RockBase.c:90
Static_rock_bright_monolith1
Definition
RockBase.c:91
Static_rock_bright_monolith2
Definition
RockBase.c:92
Static_rock_bright_monolith3
Definition
RockBase.c:93
Static_rock_bright_monolith4
Definition
RockBase.c:94
Static_rock_bright_spike1
Definition
RockBase.c:95
Static_rock_bright_spike2
Definition
RockBase.c:96
Static_rock_bright_spike3
Definition
RockBase.c:97
Static_rock_bright_wallh1
Definition
RockBase.c:98
Static_rock_bright_wallh2
Definition
RockBase.c:99
Static_rock_bright_wallh3
Definition
RockBase.c:100
Static_rock_bright_wallv
Definition
RockBase.c:101
Static_rock_monolith1
Definition
RockBase.c:102
Static_rock_monolith2
Definition
RockBase.c:103
Static_rock_monolith3
Definition
RockBase.c:104
Static_rock_monolith4
Definition
RockBase.c:105
Static_rock_spike1
Definition
RockBase.c:106
Static_rock_spike2
Definition
RockBase.c:107
Static_rock_spike3
Definition
RockBase.c:108
Static_rock_stone10_moss
Definition
RockBase.c:122
Static_rock_stone10
Definition
RockBase.c:121
Static_rock_stone6_moss
Definition
RockBase.c:114
Static_rock_stone6
Definition
RockBase.c:113
Static_rock_stone7_moss
Definition
RockBase.c:116
Static_rock_stone7
Definition
RockBase.c:115
Static_rock_stone8_moss
Definition
RockBase.c:118
Static_rock_stone8
Definition
RockBase.c:117
Static_rock_stone9_moss
Definition
RockBase.c:120
Static_rock_stone9
Definition
RockBase.c:119
Static_rock_wallh1
Definition
RockBase.c:109
Static_rock_wallh2
Definition
RockBase.c:110
Static_rock_wallh3
Definition
RockBase.c:111
Static_rock_wallv
Definition
RockBase.c:112
Static_stone1
Definition
RockBase.c:82
Static_stone2
Definition
RockBase.c:83
Static_stone3
Definition
RockBase.c:84
Static_stone4
Definition
RockBase.c:85
Static_stone5
Definition
RockBase.c:86