using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PseudoPlayer : MonoBehaviour
{
    public InventoryObject inventory;

    public delegate void AddItemEvent();
    public static event AddItemEvent OnAddItemEvent;

    public new string name;
    public int money;


    public void AddItemToInventory(Item _item, int _count)
    {
        inventory.AddItem(_item.item, _count);
        OnAddItemEvent();
    }
    public void AddItemToInventory(ItemObject _item, int _count)
    {
        inventory.AddItem(_item, _count);
        OnAddItemEvent();
    }

    private void OnApplicationQuit()
    {
        inventory.Container.Clear();
    }
}
