DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс CarWheel_Ruined
+ Граф наследования:CarWheel_Ruined:

Закрытые члены

override bool CanPutAsAttachment (EntityAI parent)
 
override void EEHealthLevelChanged (int oldLevel, int newLevel, string zone)
 

Подробное описание

Методы

◆ CanPutAsAttachment()

override bool CanPutAsAttachment ( EntityAI parent)
inlineprivate
312 {
313 // So that the lambda can always put it to the Transport
314 if (parent.IsInherited(Transport) && parent.IsRuined())
315 {
317 if (GetInventory().GetCurrentInventoryLocation(loc))
318 {
319 return loc.GetType() == InventoryLocationType.UNKNOWN;
320 }
321
322 return false;
323 }
324
325 if (!super.CanPutAsAttachment(parent))
326 return false;
327
328 return true;
329 }
InventoryLocationType
types of Inventory Location
Definition InventoryLocation.c:4
InventoryLocation.
Definition InventoryLocation.c:29
Definition EntityAI.c:95
Base native class for all motorized wheeled vehicles.
Definition Boat.c:28

◆ EEHealthLevelChanged()

override void EEHealthLevelChanged ( int oldLevel,
int newLevel,
string zone )
inlineprivate
332 {
333 super.EEHealthLevelChanged( oldLevel, newLevel, zone );
334 #ifdef DEVELOPER
335 // used when fixing the whole car through debug
337 {
338 string newWheel = "";
339 switch (GetType())
340 {
341 case "HatchbackWheel_Ruined":
342 newWheel = "HatchbackWheel";
343 break;
344
345 case "CivSedanWheel_Ruined":
346 newWheel = "CivSedanWheel";
347 break;
348
349 case "Hatchback_02_Wheel_Ruined":
350 newWheel = "Hatchback_02_Wheel";
351 break;
352
353 case "Sedan_02_Wheel_Ruined":
354 newWheel = "Sedan_02_Wheel";
355 break;
356
357 case "Truck_01_Wheel_Ruined":
358 newWheel = "Truck_01_Wheel";
359 break;
360
361 case "Truck_01_WheelDouble_Ruined":
362 newWheel = "Truck_01_WheelDouble";
363 break;
364
365 case "Offroad_02_Wheel_Ruined":
366 newWheel = "Offroad_02_Wheel";
367 break;
368 }
369
370 if (newWheel != "")
371 {
372 //Unlock to allow creating a new item
373 if (IsLockedInSlot())
375
377 lambda.SetTransferParams(true, true, true);
378 GetInventory().ReplaceItemWithNew(InventoryMode.SERVER, lambda);
379 }
380 }
381 #endif
382 }
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
Definition Inventory.c:22
eBleedingSourceType GetType()
Definition BleedingSource.c:63
void ReplaceWheelLambda(EntityAI old_item, string new_item_type, PlayerBase player)
void UnlockFromParent()
Unlocks this item from its attachment slot of its parent.
Definition ItemBase.c:5630
Definition constants.c:638
const int STATE_PRISTINE
Definition constants.c:811

Перекрестные ссылки GetType(), ReplaceWheelLambda(), GameConstants::STATE_PRISTINE и UnlockFromParent().


Объявления и описания членов класса находятся в файле: