Dayz Explorer  1.24.157551 (v105080)
Dayz Code Explorer by Zeroy
cfggameplaydatajson.c
Go to the documentation of this file.
1 class CfgGameplayJson
3 {
4  int version = -1;
5 
7  void InitServer()
8  {
9  }
10 
11  //-------------------------------------------------------------------------------------------------
12 
13 
15  ref ITEM_GeneralData GeneralData = new ITEM_GeneralData;
16  ref ITEM_PlayerData PlayerData = new ITEM_PlayerData;
17  ref ITEM_WorldData WorldsData = new ITEM_WorldData;
18  ref ITEM_BaseBuildingData BaseBuildingData = new ITEM_BaseBuildingData;
19  ref ITEM_UIData UIData = new ITEM_UIData;
20  ref ITEM_MapData MapData = new ITEM_MapData;
21 
22 };
23 
25 {
26  void ITEM_DataBase()
27  {
28  #ifdef SERVER
29  CfgGameplayHandler.RegisterItem(this);
30  #endif
31  }
32 
33  bool ValidateServer()
34  {
35  return true;
36  }
37 
38  void InitServer();
39 }
40 
41 class ITEM_GeneralData : ITEM_DataBase
42 {
43  override void InitServer()
44  {
45  disableBaseDamage = GetGame().ServerConfigGetInt( "disableBaseDamage" );
46  disableContainerDamage = GetGame().ServerConfigGetInt( "disableContainerDamage" );
47  disableRespawnDialog = GetGame().ServerConfigGetInt("disableRespawnDialog");
48  }
49 
50  override bool ValidateServer()
51  {
52  return true;
53  }
54  //-------------------------------------------------------------------------------------------------
60 
61 };
62 
63 //--------------------------------------------------------------------------------------------------------------------------------------------------
64 
66 {
67  ref ITEM_StaminaData StaminaData = new ITEM_StaminaData;
68  ref ITEM_ShockHandlingData ShockHandlingData = new ITEM_ShockHandlingData;
69  ref ITEM_MovementData MovementData = new ITEM_MovementData;
70  ref ITEM_DrowningData DrowningData = new ITEM_DrowningData;
71 
72  override void InitServer()
73  {
74  disablePersonalLight = GetGame().ServerConfigGetInt( "disablePersonalLight" );
75  }
76 
77  override bool ValidateServer()
78  {
79  return true;
80  }
81 
82  //-------------------------------------------------------------------------------------------------
84  bool disablePersonalLight;
85  bool disable2dMap;
86  ref TStringArray spawnGearPresetFiles;
87 
88 };
89 
90 //--------------------------------------------------------------------------------------------------------------------------------------------------
91 
93 {
94  override void InitServer()
95  {
96  }
97 
98  override bool ValidateServer()
99  {
100  return true;
101  }
102 
103  //-------------------------------------------------------------------------------------------------
105  float shockRefillSpeedConscious = PlayerConstants.SHOCK_REFILL_CONSCIOUS_SPEED;
106  float shockRefillSpeedUnconscious = PlayerConstants.SHOCK_REFILl_UNCONSCIOUS_SPEED;
107  bool allowRefillSpeedModifier = true;
108 };
109 
110 //--------------------------------------------------------------------------------------------------------------------------------------------------
111 
113 {
114  override void InitServer()
115  {
116  }
117 
118  override bool ValidateServer()
119  {
120  return true;
121  }
122 
123  //-------------------------------------------------------------------------------------------------
125  float staminaWeightLimitThreshold = GameConstants.STAMINA_WEIGHT_LIMIT_THRESHOLD;
126  float staminaMax = GameConstants.STAMINA_MAX;
127  float staminaKgToStaminaPercentPenalty = GameConstants.STAMINA_KG_TO_STAMINAPERCENT_PENALTY;
128  float staminaMinCap = GameConstants.STAMINA_MIN_CAP;
129  float sprintStaminaModifierErc = 1;//consumption of stamina during standing sprint modification
130  float sprintStaminaModifierCro = 1;//consumption of stamina during crouched sprint modification
131  float sprintSwimmingStaminaModifier = 1;//consumption of stamina during swimming sprint modification
132  float sprintLadderStaminaModifier = 1;//consumption of stamina during climbing sprint modification
133  float meleeStaminaModifier = 1;//consumption of stamina during melee attacks and evasion modification
134  float obstacleTraversalStaminaModifier = 1;// vaulting and climbing stamina consumption modification
135  float holdBreathStaminaModifier = 1;// hold breath stamina consumption modification
136 };
137 
138 //--------------------------------------------------------------------------------------------------------------------------------------------------
139 
141 {
142  override void InitServer()
143  {
144  }
145 
146  override bool ValidateServer()
147  {
148  return true;
149  }
150 
151  //-------------------------------------------------------------------------------------------------
153  float timeToStrafeJog = 0.1;
154  float rotationSpeedJog = 0.15;
155  float timeToSprint = 0.45;
156  float timeToStrafeSprint = 0.3;
157  float rotationSpeedSprint = 0.15;
158  bool allowStaminaAffectInertia = 1;
159 }
160 
161 //--------------------------------------------------------------------------------------------------------------------------------------------------
162 
163 class ITEM_WorldData : ITEM_DataBase
164 {
165  override void InitServer()
166  {
167  lightingConfig = GetGame().ServerConfigGetInt( "lightingConfig" );
168  wetnessWeightModifiers = {GameConstants.WEIGHT_DRY,GameConstants.WEIGHT_DAMP,GameConstants.WEIGHT_WET,GameConstants.WEIGHT_SOAKING_WET,GameConstants.WEIGHT_DRENCHED};
169  }
170 
171  override bool ValidateServer()
172  {
173  if (!wetnessWeightModifiers || wetnessWeightModifiers.Count() != 5)
174  {
175  return false;
176  }
177 
178  return true;
179  }
180 
181  //-------------------------------------------------------------------------------------------------
184 
188  ref array<float> wetnessWeightModifiers = {GameConstants.WEIGHT_DRY,GameConstants.WEIGHT_DAMP,GameConstants.WEIGHT_WET,GameConstants.WEIGHT_SOAKING_WET,GameConstants.WEIGHT_DRENCHED};
189 };
190 
191 //--------------------------------------------------------------------------------------------------------------------------------------------------
192 
194 {
195 
196  override void InitServer()
197  {
198  }
199 
200  override bool ValidateServer()
201  {
202  return true;
203  }
204 
205  //-------------------------------------------------------------------------------------------------
207  ref ITEM_HologramData HologramData = new ITEM_HologramData;
208  ref ITEM_ConstructionData ConstructionData = new ITEM_ConstructionData;
209 };
210 
211 //--------------------------------------------------------------------------------------------------------------------------------------------------
212 
214 {
215 
216  override void InitServer()
217  {
218  disallowedTypesInUnderground = new TStringSet();
219  disallowedTypesInUnderground.Insert("FenceKit");
220  disallowedTypesInUnderground.Insert("TerritoryFlagKit");
221  disallowedTypesInUnderground.Insert("WatchtowerKit");
222  }
223 
224  override bool ValidateServer()
225  {
226  return true;
227  }
228 
229  //-------------------------------------------------------------------------------------------------
231  bool disableIsCollidingBBoxCheck;
232  bool disableIsCollidingPlayerCheck;
233  bool disableIsClippingRoofCheck;
234  bool disableIsBaseViableCheck;
235  bool disableIsCollidingGPlotCheck;
236  bool disableIsCollidingAngleCheck;
237  bool disableIsPlacementPermittedCheck;
238  bool disableHeightPlacementCheck;
239  bool disableIsUnderwaterCheck;
240  bool disableIsInTerrainCheck;
241  ref TStringSet disallowedTypesInUnderground;
242 };
243 
244 //--------------------------------------------------------------------------------------------------------------------------------------------------
245 
247 {
248 
249  override void InitServer()
250  {
251  }
252 
253  override bool ValidateServer()
254  {
255  return true;
256  }
257 
258  //-------------------------------------------------------------------------------------------------
260  bool disablePerformRoofCheck;
261  bool disableIsCollidingCheck;
262  bool disableDistanceCheck;
263 };
264 
265 //--------------------------------------------------------------------------------------------------------------------------------------------------
266 
269 {
270  override void InitServer()
271  {
272  HitIndicationData.InitServer();
273  }
274 
275  override bool ValidateServer()
276  {
277  return true;
278  }
279 
280  //-------------------------------------------------------------------------------------------------
282  ref ITEM_HitIndicationData HitIndicationData = new ITEM_HitIndicationData;
283  bool use3DMap = false;
284 };
285 
286 //--------------------------------------------------------------------------------------------------------------------------------------------------
287 
289 {
290  override void InitServer()
291  {
292  hitDirectionOverrideEnabled = false;
293  hitIndicationPostProcessEnabled = false;
294  }
295 
296  override bool ValidateServer()
297  {
298  return true;
299  }
300 
301  //-------------------------------------------------------------------------------------------------
304  bool hitDirectionOverrideEnabled = false;
305  int hitDirectionBehaviour = HitDirectionModes.STATIC;
306  int hitDirectionStyle = HitIndicatorType.SPLASH;
307  string hitDirectionIndicatorColorStr;
308  float hitDirectionMaxDuration = HitDirectionConstants.DURATION_BASE;
309  float hitDirectionBreakPointRelative = HitDirectionConstants.BREAKPOINT_BASE;
310  float hitDirectionScatter = HitDirectionConstants.SCATTER;
311  bool hitIndicationPostProcessEnabled = false;
312 };
313 
314 //--------------------------------------------------------------------------------------------------------------------------------------------------
315 
317 {
318  override void InitServer()
319  {
320  }
321 
322  override bool ValidateServer()
323  {
324  return true;
325  }
326 
327  //-------------------------------------------------------------------------------------------------
329  bool ignoreMapOwnership = false;
330  bool ignoreNavItemsOwnership = false;
331  bool displayPlayerPosition = false;
332  bool displayNavInfo = true;
333 }
334 
335 //--------------------------------------------------------------------------------------------------------------------------------------------------
336 
337 class ITEM_DrowningData : ITEM_DataBase
338 {
339  override void InitServer()
340  {
341  }
342 
343  override bool ValidateServer()
344  {
345  return true;
346  }
347 
348  //-------------------------------------------------------------------------------------------------
353 }
GetGame
proto native CGame GetGame()
ITEM_UIData
data for UI, in-game HUD, and similar
Definition: cfggameplaydatajson.c:268
environmentMinTemps
ref array< float > environmentMinTemps
Definition: cfggameplaydatajson.c:186
wetnessWeightModifiers
ref array< float > wetnessWeightModifiers
Definition: cfggameplaydatajson.c:188
ITEM_HologramData
Definition: cfggameplaydatajson.c:213
healthDepletionSpeed
float healthDepletionSpeed
Definition: cfggameplaydatajson.c:351
ITEM_ShockHandlingData
Definition: cfggameplaydatajson.c:92
lightingConfig
int lightingConfig
!! all member variables must correspond with the cfggameplay.json file contents !!...
Definition: cfggameplaydatajson.c:183
objectSpawnersArr
ref array< string > objectSpawnersArr
Definition: cfggameplaydatajson.c:185
CfgGameplayJson
contents of this class will be transfered to client upon connecting, with the variables in either ini...
Definition: cfggameplaydatajson.c:2
disableBaseDamage
bool disableBaseDamage
!! all member variables must correspond with the cfggameplay.json file contents !!...
Definition: cfggameplaydatajson.c:56
InitServer
ITEM_PlayerData InitServer
Definition: cfggameplaydatajson.c:43
environmentMaxTemps
ref array< float > environmentMaxTemps
Definition: cfggameplaydatajson.c:187
disableRespawnInUnconsciousness
bool disableRespawnInUnconsciousness
Definition: cfggameplaydatajson.c:59
shockDepletionSpeed
float shockDepletionSpeed
Definition: cfggameplaydatajson.c:352
HitDirectionModes
HitDirectionModes
Definition: constants.c:97
ITEM_MapData
Definition: cfggameplaydatajson.c:316
ITEM_PlayerData
Definition: cfggameplaydatajson.c:65
ITEM_StaminaData
Definition: cfggameplaydatajson.c:112
PlayerConstants
Definition: playerconstants.c:1
ITEM_BaseBuildingData
Definition: cfggameplaydatajson.c:193
CfgGameplayHandler
Definition: cfggameplayhandler.c:1
array< string >
ITEM_DataBase
Definition: cfggameplaydatajson.c:24
ITEM_HitIndicationData
Definition: cfggameplaydatajson.c:288
disableRespawnDialog
bool disableRespawnDialog
Definition: cfggameplaydatajson.c:58
ValidateServer
bool ValidateServer()
Definition: cfggameplaydatajson.c:9
GameConstants
Definition: constants.c:612
staminaDepletionSpeed
float staminaDepletionSpeed
!! all member variables must correspond with the cfggameplay.json file contents !!...
Definition: cfggameplaydatajson.c:350
ITEM_ConstructionData
Definition: cfggameplaydatajson.c:246
disableContainerDamage
bool disableContainerDamage
Definition: cfggameplaydatajson.c:57
ITEM_MovementData
Definition: cfggameplaydatajson.c:140
TStringSet
set< string > TStringSet
Definition: enscript.c:775