MVC shop project for software architecture, in Unity.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

18 lines
580 B

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
/// <summary>
/// This item factory literally just takes a handcrafted list of items and populates the model with that!
/// </summary>
[CreateAssetMenu]//Allows creating ViewConfig objects in Assets -> Create menu in the Unity Editor
public class ScriptedItemFactory : ItemFactory
{
public List<ScriptedItem> Items;
public override void PopulateInventory(Inventory model)
{
foreach (var item in Items)
{
model.AddItem(item.GenerateItem());
}
}
}