Esempio n. 1
0
        /// <summary>
        /// Creates an instance of <see cref="WeaponProficiencyModel"/>
        /// </summary>
        public WeaponProficiencyModel(WeaponProficiencyModel armorProficiencyModel)
        {
            _simpleWeaponsProficiency  = armorProficiencyModel.SimpleWeaponsProficiency;
            _martialWeaponsProficiency = armorProficiencyModel.MartialWeaponsProficiency;

            _clubProficiency          = armorProficiencyModel.ClubProficiency;
            _daggerProficiency        = armorProficiencyModel.DaggerProficiency;
            _greatclubProficiency     = armorProficiencyModel.GreatclubProficiency;
            _handaxeProficiency       = armorProficiencyModel.HandaxeProficiency;
            _javelinProficiency       = armorProficiencyModel.JavelinProficiency;
            _lightHammerProficiency   = armorProficiencyModel.LightHammerProficiency;
            _maceProficiency          = armorProficiencyModel.MaceProficiency;
            _quarterstaffProficiency  = armorProficiencyModel.QuarterstaffProficiency;
            _sickleProficiency        = armorProficiencyModel.SickleProficiency;
            _spearProficiency         = armorProficiencyModel.SpearProficiency;
            _crossbowLightProficiency = armorProficiencyModel.CrossbowLightProficiency;
            _dartProficiency          = armorProficiencyModel.DartProficiency;
            _shortbowProficiency      = armorProficiencyModel.ShortbowProficiency;
            _slingProficiency         = armorProficiencyModel.SlingProficiency;

            _battleaxeProficiency     = armorProficiencyModel.BattleaxeProficiency;
            _flailProficiency         = armorProficiencyModel.FlailProficiency;
            _glaiveProficiency        = armorProficiencyModel.GlaiveProficiency;
            _greataxeProficiency      = armorProficiencyModel.GreataxeProficiency;
            _greatswordProficiency    = armorProficiencyModel.GreatswordProficiency;
            _halberdProficiency       = armorProficiencyModel.HalberdProficiency;
            _lanceProficiency         = armorProficiencyModel.LanceProficiency;
            _longswordProficiency     = armorProficiencyModel.LongswordProficiency;
            _maulProficiency          = armorProficiencyModel.MaulProficiency;
            _morningstarProficiency   = armorProficiencyModel.MorningstarProficiency;
            _pikeProficiency          = armorProficiencyModel.PikeProficiency;
            _rapierProficiency        = armorProficiencyModel.RapierProficiency;
            _scimitarProficiency      = armorProficiencyModel.ScimitarProficiency;
            _shortswordProficiency    = armorProficiencyModel.ShortswordProficiency;
            _tridentProficiency       = armorProficiencyModel.TridentProficiency;
            _warPickProficiency       = armorProficiencyModel.WarPickProficiency;
            _warhammerProficiency     = armorProficiencyModel.WarhammerProficiency;
            _whipProficiency          = armorProficiencyModel.WhipProficiency;
            _blowgunProficiency       = armorProficiencyModel.BlowgunProficiency;
            _crossbowHandProficiency  = armorProficiencyModel.CrossbowHandProficiency;
            _crossbowHeavyProficiency = armorProficiencyModel.CrossbowHeavyProficiency;
            _longbowProficiency       = armorProficiencyModel.LongbowProficiency;
            _netProficiency           = armorProficiencyModel.NetProficiency;
        }
Esempio n. 2
0
        /// <summary>
        /// Gets weapon proficiency string
        /// </summary>
        public string GetWeaponProficiencyString(WeaponProficiencyModel weaponProficiency)
        {
            List <string> weapons = new List <string>();

            if (weaponProficiency.SimpleWeaponsProficiency)
            {
                weapons.Add(GetString(SimpleWeapon.All));
            }
            else
            {
                if (weaponProficiency.ClubProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Club));
                }
                if (weaponProficiency.DaggerProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Dagger));
                }
                if (weaponProficiency.GreatclubProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Greatclub));
                }
                if (weaponProficiency.HandaxeProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Handaxe));
                }
                if (weaponProficiency.JavelinProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Javelin));
                }
                if (weaponProficiency.LightHammerProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.LightHammer));
                }
                if (weaponProficiency.MaceProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Mace));
                }
                if (weaponProficiency.QuarterstaffProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Quarterstaff));
                }
                if (weaponProficiency.SickleProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Sickle));
                }
                if (weaponProficiency.SpearProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Spear));
                }
                if (weaponProficiency.CrossbowLightProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.CrossbowLight));
                }
                if (weaponProficiency.DartProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Dart));
                }
                if (weaponProficiency.ShortbowProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Shortbow));
                }
                if (weaponProficiency.SlingProficiency)
                {
                    weapons.Add(GetString(SimpleWeapon.Sling));
                }
            }

            if (weaponProficiency.MartialWeaponsProficiency)
            {
                weapons.Add(GetString(MartialWeapon.All));
            }
            else
            {
                if (weaponProficiency.BattleaxeProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Battleaxe));
                }
                if (weaponProficiency.FlailProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Flail));
                }
                if (weaponProficiency.GlaiveProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Glaive));
                }
                if (weaponProficiency.GreataxeProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Greataxe));
                }
                if (weaponProficiency.GreatswordProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Greatsword));
                }
                if (weaponProficiency.HalberdProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Halberd));
                }
                if (weaponProficiency.LanceProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Lance));
                }
                if (weaponProficiency.LongswordProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Longsword));
                }
                if (weaponProficiency.MaulProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Maul));
                }
                if (weaponProficiency.MorningstarProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Morningstar));
                }
                if (weaponProficiency.PikeProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Pike));
                }
                if (weaponProficiency.RapierProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Rapier));
                }
                if (weaponProficiency.ScimitarProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Scimitar));
                }
                if (weaponProficiency.ShortswordProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Shortsword));
                }
                if (weaponProficiency.TridentProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Trident));
                }
                if (weaponProficiency.WarPickProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.WarPick));
                }
                if (weaponProficiency.WarhammerProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Warhammer));
                }
                if (weaponProficiency.WhipProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Whip));
                }
                if (weaponProficiency.BlowgunProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Blowgun));
                }
                if (weaponProficiency.CrossbowHandProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.CrossbowHand));
                }
                if (weaponProficiency.CrossbowHeavyProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.CrossbowHeavy));
                }
                if (weaponProficiency.LongbowProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Longbow));
                }
                if (weaponProficiency.NetProficiency)
                {
                    weapons.Add(GetString(MartialWeapon.Net));
                }
            }

            return(weapons.Any() ? String.Join(", ", weapons) : "None");
        }
 /// <summary>
 /// Creates an instance of <see cref="WeaponProficiencyViewModel"/>
 /// </summary>
 public WeaponProficiencyViewModel(WeaponProficiencyModel weaponProficiencyModel)
 {
     _weaponProficiencyModel = weaponProficiencyModel;
 }