public DropTable.DropData CreateFrom(DropTable.DropData data) { DropTable.DropData itemData = new DropTable.DropData(); itemData.m_item = data.m_item; itemData.m_weight = Weight; itemData.m_stackMin = StackMin; itemData.m_stackMax = StackMax; return(itemData); }
// Token: 0x06000689 RID: 1673 RVA: 0x00036990 File Offset: 0x00034B90 private void AddItemToList(List <ItemDrop.ItemData> toDrop, DropTable.DropData data) { ItemDrop.ItemData itemData = data.m_item.GetComponent <ItemDrop>().m_itemData; ItemDrop.ItemData itemData2 = itemData.Clone(); itemData2.m_dropPrefab = data.m_item; int min = Mathf.Max(1, data.m_stackMin); int num = Mathf.Min(itemData.m_shared.m_maxStackSize, data.m_stackMax); itemData2.m_stack = UnityEngine.Random.Range(min, num + 1); toDrop.Add(itemData2); }
public static string DropDataToString(DropTable.DropData x) { return($"[m_item={GameObjectToString(x.m_item)}, m_stackMin={x.m_stackMin}, m_stackMax={x.m_stackMax}, m_weight={x.m_weight}]"); }