public bool Write(DAIIO io, bool skiplength = false)
        {
            try
            {
                if (ItemStats == null)
                {
                    ItemStats = new ItemStatsData[StatsCount];

                    for (int xb = 0; xb < StatsCount; xb++)
                    {
                        ItemStats[xb] = new ItemStatsData();
                    }
                }
                io.WriteInt16((short)ItemStats.Length);
                foreach (ItemStatsData t in ItemStats)
                {
                    t.Write(io);
                }

                return(true);
            }
            catch (Exception)
            {
                return(false);
            }
        }
 public ItemDynamicStats Read(DAIIO io)
 {
     StatsCount = io.ReadInt16();
     ItemStats  = new ItemStatsData[StatsCount];
     for (int i = 0; i < StatsCount; i++)
     {
         ItemStats[i] = new ItemStatsData().Read(io);
     }
     return(this);
 }