Exemple #1
0
 public void ClearLists()
 {
     AAGuns.Clear();
     AuxiliaryItems.Clear();
     SubmarineTorpedoes.Clear();
     Torpedoes.Clear();
     TorpedoBomberPlanes.Clear();
     MainGuns.Clear();
     Planes.Clear();
     AswItems.Clear();
 }
Exemple #2
0
        private void AddItemToList(Equipment item, string newType, DPSData dpsData)
        {
            switch (newType)
            {
            case "AA Gun":
                AAGuns.Add(new AAGun(item, dpsData));
                break;

            case "Auxiliary":
                AuxiliaryItems.Add(new AuxiliaryItem(item));
                break;

            case "Submarine Torpedo":
                SubmarineTorpedoes.Add(new SubmarineTorpedo(item, dpsData));
                break;

            case "Torpedo":
                Torpedoes.Add(new Torpedo(item, dpsData));
                break;

            case "Torpedo Bomber":
                TorpedoBomberPlanes.Add(new TorpedoBomberPlane(item, dpsData));
                break;

            case string s when s.Contains("Gun"):
                MainGuns.Add(new MainGun(item, dpsData));

                break;

            case string s when s == "Fighter" || s == "Dive Bomber" || s == "Seaplane":
                Planes.Add(new Plane(item, dpsData));
                break;

            default:
                AswItems.Add(new ASWItem(item));
                break;
            }
        }