using System;
using System.Text;


namespace ActionGame.GameResources.Models
{
    public class ItemDefinition
    {
        public enum ItemType { Weapon=0, Instant=1, Consumable=2};

        public Int32 Key { get; set; }
        public String Name { get; set; }
        public Int32 ItemTypeKey { get; set; }
        public Int32 TextureKey { get; set; }
        public Boolean IsFixedPower { get; set; }
        public Int32 Power { get; set; }
        public String Description { get; set; }
        public Int32 MaxCapacity { get; set; }


        public static String GetCsvTitle()
        {
            return "Key,Name,ItemTypeKey,TextureKey,IsFixedPower,Power,Description,MaxCapacity";
        }


        public String ToCsvString()
        {
            StringBuilder line = new StringBuilder();

            line.Append(Key);
            line.Append(',');
            line.Append(Name);
            line.Append(',');
            line.Append(ItemTypeKey);
            line.Append(',');
            line.Append(TextureKey);
            line.Append(',');
            line.Append(IsFixedPower);
            line.Append(',');
            line.Append(Power);
            line.Append(',');
            line.Append(Description);
            line.Append(',');
            line.Append(MaxCapacity);

            return line.ToString();
        }



    }
}
