25 SetEnginePos(
"0 0.7 1.2");
49 super.OnEngineStart();
119 if (!super.CanReleaseAttachment(attachment))
126 string attType = attachment.GetType();
127 if (attType ==
"CarRadiator" || attType ==
"CarBattery" || attType ==
"SparkPlug")
143 if (!super.CanDisplayAttachmentCategory(category_name))
149 if (category_name.
Contains(
"engine"))
162 if (!super.CanDisplayCargo())
179 Class.
CastTo(carDoor, FindAttachmentBySlotName(slotType));
187 case "NivaDriverDoors":
190 case "NivaCoDriverDoors":
211 else if (GetAnimationPhase(
"SeatDriver") > 0.5)
219 else if (GetAnimationPhase(
"SeatCoDriver") > 0.5)
227 else if (GetAnimationPhase(
"SeatDriver") <= 0.5)
235 else if (GetAnimationPhase(
"SeatCoDriver") <= 0.5)
250 return "doors_driver";
253 return "doors_codriver";
256 return super.GetDoorSelectionNameFromSeatPos(posIdx);
265 return "NivaDriverDoors";
268 return "NivaCoDriverDoors";
271 return super.GetDoorInvSlotNameFromSeatPos(posIdx);
318 return super.OnSound(ctrl, oldValue);
326 return "DoorsDriver";
327 case "doors_codriver":
328 return "DoorsCoDriver";
333 case "seatback_driver":
335 case "seatback_codriver":
336 return "SeatCoDriver";
347 case "seatback_driver":
349 return "seat_con_1_1";
350 case "seat_codriver":
351 case "seatback_codriver":
353 return "seat_con_2_1";
363 case "seatback_driver":
365 case "seatback_codriver":
384 if (nextSeat == 0 && GetAnimationPhase(
"SeatDriver") > 0.5)
387 if (nextSeat == 1 && GetAnimationPhase(
"SeatCoDriver") > 0.5)
393 return nextSeat == 1;
396 return nextSeat == 0;
399 return nextSeat == 3;
402 return nextSeat == 2;
410 switch (pCurrentSeat)
413 return pDoorsSelection ==
"DoorsDriver";
416 return pDoorsSelection ==
"DoorsCoDriver";
419 return pDoorsSelection ==
"DoorsDriver";
422 return pDoorsSelection ==
"DoorsCoDriver";
430 switch (pDoorSelection)
434 case "DoorsCoDriver":
454 GetInventory().CreateInInventory(
"HatchbackWheel");
455 GetInventory().CreateInInventory(
"HatchbackWheel");
456 GetInventory().CreateInInventory(
"HatchbackWheel" );
457 GetInventory().CreateInInventory(
"HatchbackWheel");
459 GetInventory().CreateInInventory(
"HatchbackDoors_Driver");
460 GetInventory().CreateInInventory(
"HatchbackDoors_CoDriver");
461 GetInventory().CreateInInventory(
"HatchbackHood");
462 GetInventory().CreateInInventory(
"HatchbackTrunk");
465 GetInventory().CreateInInventory(
"HatchbackWheel");
466 GetInventory().CreateInInventory(
"HatchbackWheel");
478 GetInventory().CreateInInventory(
"HatchbackWheel");
479 GetInventory().CreateInInventory(
"HatchbackWheel");
480 GetInventory().CreateInInventory(
"HatchbackWheel");
481 GetInventory().CreateInInventory(
"HatchbackWheel");
483 GetInventory().CreateInInventory(
"HatchbackDoors_Driver_White");
484 GetInventory().CreateInInventory(
"HatchbackDoors_CoDriver_White");
485 GetInventory().CreateInInventory(
"HatchbackHood_White");
486 GetInventory().CreateInInventory(
"HatchbackTrunk_White");
489 GetInventory().CreateInInventory(
"HatchbackWheel");
490 GetInventory().CreateInInventory(
"HatchbackWheel");
502 GetInventory().CreateInInventory(
"HatchbackWheel");
503 GetInventory().CreateInInventory(
"HatchbackWheel");
504 GetInventory().CreateInInventory(
"HatchbackWheel");
505 GetInventory().CreateInInventory(
"HatchbackWheel");
507 GetInventory().CreateInInventory(
"HatchbackDoors_Driver_Blue");
508 GetInventory().CreateInInventory(
"HatchbackDoors_CoDriver_Blue");
509 GetInventory().CreateInInventory(
"HatchbackHood_Blue");
510 GetInventory().CreateInInventory(
"HatchbackTrunk_Blue");
513 GetInventory().CreateInInventory(
"HatchbackWheel");
514 GetInventory().CreateInInventory(
"HatchbackWheel");
void AddAction(typename actionName)
CarSoundCtrl
Car's sound controller list. (native, do not change or extend)
string m_CarSeatShiftInSound
CarDoorState TranslateAnimationPhaseToCarDoorState(string animation)
protected void SpawnUniversalParts()
string m_EngineStartOK
Sounds.
protected void FillUpCarFluids()
string m_CarDoorCloseSound
string m_EngineStartBattery
protected void SpawnAdditionalItems()
string m_CarHornShortSoundName
string m_CarHornLongSoundName
string m_CarSeatShiftOutSound
string m_CarDoorOpenSound
protected ref UniversalTemperatureSourceSettings m_UTSSettings
override int GetCarDoorsState(string slotType)
protected ref UniversalTemperatureSource m_UTSource
protected ref UniversalTemperatureSourceLambdaEngine m_UTSLEngine
override int GetCarDoorsState(string slotType)
override void OnDebugSpawn()
override bool CanDisplayAttachmentCategory(string category_name)
override void EOnPostSimulate(IEntity other, float timeSlice)
override float GetTransportCameraDistance()
override bool IsVitalGlowPlug()
override bool CanReachDoorsFromSeat(string pDoorsSelection, int pCurrentSeat)
override bool CanDisplayCargo()
override int GetAnimInstance()
override bool CrewCanGetThrough(int posIdx)
override CarLightBase CreateFrontLight()
override int GetSeatIndexFromDoor(string pDoorSelection)
override CarRearLightBase CreateRearLight()
override float OnSound(CarSoundCtrl ctrl, float oldValue)
override bool IsVitalTruckBattery()
override int GetCrewIndex(string selection)
override bool CanReleaseAttachment(EntityAI attachment)
override void OnEngineStart()
override string GetAnimSourceFromSelection(string selection)
override bool CanReachSeatFromSeat(int currentSeat, int nextSeat)
override protected bool CanManipulateSpareWheel(string slotSelectionName)
override string GetDoorConditionPointFromSelection(string selection)
override string GetDoorSelectionNameFromSeatPos(int posIdx)
override int GetSeatAnimationType(int posIdx)
override string GetDoorInvSlotNameFromSeatPos(int posIdx)
override void SetActions()
override void OnEngineStop()
Super root of all classes in Enforce script.
override void OnDebugSpawn()
original Timer deletes m_params which is unwanted
float m_TemperatureMax
min temperature you can get from the TemperatureSource
float m_RangeFull
temperature cap that will limit the return value from GetTemperature method
bool m_ManualUpdate
if the Update is running periodically
float m_TemperatureMin
how often the Update is ticking
float m_RangeMax
range where the full temperature is given to receiver
float m_TemperatureCap
max temperature you can get from the TemperatureSource
DayZPlayerConstants
defined in C++
proto native CGame GetGame()
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.
bool Contains(string sample)
Returns true if sample is substring of string.
proto int ToLower()
Changes string to lowercase. Returns length.