Пример #1
0
            public static string FromSettings(Settings.Weapon weapon)
            {
                switch (weapon)
                {
                case Settings.MiniGun _: return(MiniGun);

                case Settings.Vulcan _: return(Vulcan);

                default:
                    throw new ArgumentOutOfRangeException(nameof(weapon));
                }
            }
 public void Init(Settings.Weapon weaponSettings, Point topLeft, int width)
 {
     WeaponSettings = weaponSettings;
     Init(new Rectangle(topLeft, new Point(width, Height)));
 }