public void Load(BoostCollectionSave save)
 {
     save.Guard();
     Boosts.Clear();
     foreach (var kvp in save.boosts)
     {
         BoostInfo boost = new BoostInfo(kvp.Value);
         Add(boost);
     }
 }
Beispiel #2
0
        public void Guard()
        {
            if (profitBoosts == null)
            {
                profitBoosts = new BoostCollectionSave();
            }

            if (timeBoosts == null)
            {
                timeBoosts = new BoostCollectionSave();
            }
        }
Beispiel #3
0
 public void Guard()
 {
     if (generators == null)
     {
         generators = new List <GeneratorInfoSave>();
     }
     if (profitSave == null)
     {
         profitSave = new BoostCollectionSave();
         profitSave.Guard();
     }
     if (timeSave == null)
     {
         timeSave = new BoostCollectionSave();
         timeSave.Guard();
     }
 }