public void DeserializeData(object[] Target, int ItemsToExpect, ArcenDeserializationBuffer Buffer, bool IsLoadingFromNetwork, GameVersion DeserializingFromGameVersion)
        {
            for (Items itemEnum = 0; itemEnum < Items.Length && (int)itemEnum < ItemsToExpect; itemEnum++)
            {
                if (!Buffer.ReadBool())
                {
                    continue;
                }
                switch (itemEnum)
                {
                case Items.Primitives:
                {
                    Primitives item = ( Primitives)Target[(int)itemEnum];

                    item.SecondsUntilNextDoomAttack          = Buffer.ReadInt32();
                    item.LastDoomAttackLaunchedAgainstPlayer = Buffer.ReadBool();
                    item.SecondsUntilNextDoomPlanetPick      = Buffer.ReadInt32();
                }
                break;

                case Items.DoomedPlanetIndices:
                {
                    List <int> item = new List <int>();
                    Target[(int)Items.DoomedPlanetIndices] = item;

                    int countToExpect = Buffer.ReadInt32();
                    for (int i = 0; i < countToExpect; i++)
                    {
                        item.Add(Buffer.ReadInt32());
                    }
                }
                break;
                }
            }
        }
 /// <summary>
 /// Used to load our data.
 /// </summary>
 /// <remarks>
 /// Make sure that loading order is the same as the saving order.
 /// </remarks>
 /// <param name="Buffer"></param>
 public CivilianWorld(ArcenDeserializationBuffer Buffer)
 {
     Version = Buffer.ReadInt32(ReadStyle.NonNeg);
     this.GeneratedResources = Buffer.ReadBool();
 }