DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ EEItemLocationChanged()

override void Mask_Base::EEItemLocationChanged ( notnull InventoryLocation oldLoc,
notnull InventoryLocation newLoc )
inlineprivate

См. определение в файле MouthRag.c строка 25

26 {
27 super.EEItemLocationChanged(oldLoc,newLoc);
28
29 if (GetGame().IsDedicatedServer())
30 {
31 PlayerBase playerOld;
32 PlayerBase playerNew;
33 if (oldLoc.GetParent())
34 Class.CastTo(playerOld,oldLoc.GetParent().GetHierarchyRootPlayer());
35 if (newLoc.GetParent())
36 Class.CastTo(playerNew,newLoc.GetParent().GetHierarchyRootPlayer());
37
38 if (newLoc.GetType() == InventoryLocationType.GROUND)
39 {
40 ItemBase newItem;
41 if (Class.CastTo(newItem,GetGame().CreateObjectEx("Rag",newLoc.GetPos(),ECE_PLACE_ON_SURFACE,RF_DEFAULT)))
42 {
43 MiscGameplayFunctions.TransferItemProperties(this,newItem);
44 newItem.SetQuantity(1);
45 DeleteSafe();
46 }
47 }
48 }
49 }
const int ECE_PLACE_ON_SURFACE
Определения CentralEconomy.c:37
const int RF_DEFAULT
Определения CentralEconomy.c:65
class GP5GasMask extends MaskBase ItemBase
InventoryLocationType
types of Inventory Location
Определения InventoryLocation.c:4
override bool SetQuantity(float value, bool destroy_config=true, bool destroy_forced=false, bool allow_client=false, bool clamp_to_stack_max=true)
Определения PileOfWoodenPlanks.c:88
proto native CGame GetGame()

Перекрестные ссылки Class::CastTo(), ECE_PLACE_ON_SURFACE, GetGame(), RF_DEFAULT и ItemBase::SetQuantity().