Exemple #1
0
 protected void AddItemForUI()
 {
     for (int i = 0; i < this.inventoryUI.NumberOfSlots; i++)
     {
         this.inventoryUI.AddNewItem(this.characterItems[ChanceOfDrop.DropChance(playerStats, new int[] { indexCommon, indexRare, indexEpic, indexMythic, indexLegendary })]);/*, indexRare, indexEpic,  indexMythic,  indexLegendary*//*)]);*/
     }
 }
 private void BuildDataBase()
 {
     items = new List <Item>();
     Item[] itemBase = Resources.LoadAll <Item>("Items");
     foreach (Item elem in itemBase)
     {
         elem.CrateStats();
         items.Add(elem);
     }
     ChanceOfDrop.SortInventory(items);
 }