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

◆ Do()

override void CraftTorch::Do ( ItemBase ingredients[],
PlayerBase player,
array< ItemBase > results,
float specialty_weight )
inlineprivate

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

66 {
67 ItemBase rag = ingredients[0];
68 rag.SetCleanness(0);
69 Torch torch = Torch.Cast(results[0]);
70
71 int quantity = rag.GetQuantity();
72
73 if (torch)
74 {
75 torch.SetTorchDecraftResult(ingredients[1].GetType());
76
77 if (GetGame().IsMultiplayer() && GetGame().IsServer())
78 {
79 player.ServerTakeEntityToTargetAttachment(torch, rag);
80 }
81 else if (!GetGame().IsMultiplayer())
82 {
83 int slotID = InventorySlots.GetSlotIdFromString("Rags");
84 player.PredictiveTakeEntityToTargetAttachmentEx(torch, rag, slotID);
85
86 }
87
88 torch.StandUp();
89 torch.CraftingInit(quantity); // original rag is set for delete at this point so quantity from it cant be used
90 }
91 }
eBleedingSourceType GetType()
Определения BleedingSource.c:63
class GP5GasMask extends MaskBase ItemBase
proto native CGame GetGame()

Перекрестные ссылки GetGame(), InventorySlots::GetSlotIdFromString() и GetType().