当前位置: 首页>>代码示例>>C#>>正文


C# Mobile.EquipItem方法代码示例

本文整理汇总了C#中Server.Mobile.EquipItem方法的典型用法代码示例。如果您正苦于以下问题:C# Mobile.EquipItem方法的具体用法?C# Mobile.EquipItem怎么用?C# Mobile.EquipItem使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Server.Mobile的用法示例。


在下文中一共展示了Mobile.EquipItem方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: OnDoubleClick

 public override void OnDoubleClick( Mobile m )
 {
    if( Parent != m )
    {
       m.SendMessage( "You can not use this item from your pack!" );
    }
    else
    {
       if ( ItemID == 0x2683 || ItemID == 0x2684 )
       {
          m.SendMessage( "You lower the hood." );
          m.PlaySound( 0x57 );
          ItemID = 0x1F03;
          m.NameMod = null;
          LootType=LootType.Blessed;
          m.RemoveItem(this);
          m.EquipItem(this);
       }
       else if ( ItemID == 0x1F03 || ItemID == 0x1F04 )
       {
          m.SendMessage( "You pull the hood over your head." );
          m.PlaySound( 0x57 );
          ItemID = 0x2683;
          LootType=LootType.Blessed;
          m.RemoveItem(this);
          m.EquipItem(this);
       }
    }
 }
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:29,代码来源:BaseHoodedShroud.cs

示例2: OnDoubleClick

        public override void OnDoubleClick( Mobile m )
      {
         if( Parent != m )
         {
            m.SendMessage( "You must be wearing the robe to use it!" );
         }
         else
         {
            if ( ItemID == 0x2683 || ItemID == 0x2684 )
            {
               m.SendMessage( "You lower the hood." );
               m.PlaySound( 0x57 );
               ItemID = 0x1F03;
               m.NameMod = null;
               m.RemoveItem(this);
               m.EquipItem(this);

            }
            else if ( ItemID == 0x1F03 || ItemID == 0x1F04 )
            {
               m.SendMessage( "You pull the hood over your head." );
               m.PlaySound( 0x57 );
               ItemID = 0x2683;
               m.RemoveItem(this);
               m.EquipItem(this);

            }
         }
      }
开发者ID:Tukaramdas,项目名称:ServUO-EC-Test-Fork,代码行数:29,代码来源:RamaRobe.cs

示例3: Dress

		private static void Dress( Mobile m, ArrayList items )
		{
			foreach( Item i in items )
			{
				m.EquipItem( i );
			}
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:7,代码来源:BaseMobileHelper.cs

示例4: OnEquip

		public override bool OnEquip( Mobile from )
		{
			if ( ItemID == 0x204F )
			{
				from.Title = "[Owner]";
				from.DisplayGuildTitle = false;
			}

			Container mobilePack = from.Backpack;

			Item bracelet = from.FindItemOnLayer( Layer.Bracelet );

			if ( bracelet != null )
			{
				mobilePack.DropItem( bracelet );
			}

			GoldBracelet brace = new GoldBracelet();
  			brace.Movable = false;
			brace.Attributes.LowerManaCost = 100;
			brace.Attributes.LowerRegCost = 100;
			brace.Attributes.RegenHits = 100;
			brace.Attributes.RegenStam = 100;
			brace.Attributes.RegenMana = 100;
			brace.Attributes.SpellDamage = 100;
			brace.Attributes.CastRecovery = 12;
			brace.Attributes.CastSpeed = 12;
			from.EquipItem( brace );
			return base.OnEquip( from );
		}
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:30,代码来源:OwnerRobe.cs

示例5: OnDoubleClick

        // nickfly|gorgan edits for equip method - start

        public override void OnDoubleClick(Mobile from)
        {
            if (!this.Movable)
            {
                from.SendMessage("That item cannot be moved, let alone equipped. Nice try.");
                return;
            }

            if (from.FindItemOnLayer(this.Layer) == this)
            {
                from.Backpack.DropItem(this);
                //from.SendMessage("");
                return;
            }

            if (Parent != from)
            {
                if (!from.InRange(this.GetWorldLocation(), 2))
                {
                    from.LocalOverheadMessage(MessageType.Regular, 906, 1019045); //I can't reach that.
                    return;
                }
            }

            if (!from.Backpack.TryDropItem(from, this, false))
            {
                from.SendMessage("You don't have enough room in your backpack.");
                return;
            }

            if (this.Layer == Layer.TwoHanded)
            {
                from.Backpack.DropItem(from.FindItemOnLayer(Layer.TwoHanded));
                from.Backpack.DropItem(from.FindItemOnLayer(Layer.FirstValid));
                from.EquipItem(this);
                return;
            }

            if (from.FindItemOnLayer(this.Layer) != this)
            {
                from.Backpack.DropItem(from.FindItemOnLayer(this.Layer));
                from.EquipItem(this);
                //from.SendMessage("");
                return;
            }
        }
开发者ID:greeduomacro,项目名称:annox,代码行数:48,代码来源:BaseClothing.cs

示例6: OnDoubleClick

      public override void OnDoubleClick( Mobile m )
      {
         if( Parent != m )
         {
            m.SendMessage( "You must be wearing the robe to use it!" );
         }
         else
         {
            if ( ItemID == 0x2683 || ItemID == 0x2684 )
            {
               m.SendMessage( "You lower the hood." );
               m.PlaySound( 0x57 );
               ItemID = 0x1F03;
               m.NameMod = null;
               m.RemoveItem(this);
               m.EquipItem(this);
               /*if( m.Kills >= 5)
               {
               m.Criminal = true;
                }
                if( m.GuildTitle != null)
               {
                  m.DisplayGuildTitle = true;
                }*/
            }
            else if ( ItemID == 0x1F03 || ItemID == 0x1F04 )
            {
               m.SendMessage( "You pull the hood over your head." );
               m.PlaySound( 0x57 );
               ItemID = 0x2683;
               //m.NameMod = "shrouded figure";
               //m.ShowFameTitle = false;
               //m.DisplayGuildTitle = false;
               //m.Criminal = false;
               //m.Title = "a";
               m.RemoveItem(this);
               m.EquipItem(this);

            }
         }
      }
开发者ID:greeduomacro,项目名称:GoUO,代码行数:41,代码来源:HoodedRobe.cs

示例7: OnDoubleClick

		public override void OnDoubleClick( Mobile m )
		{
			if( Parent != m )
			{
				m.SendMessage( "ALWAYS WEAR YOUR STAFF ROBE!" );
			}
			else
			{
				if ( ItemID == 0x204F || ItemID == 0x204F )
				{
					m.SendMessage( "YOU ARE NOW PRIVATE." );
					m.PlaySound( 0x57 );
					ItemID = 0x1F03;
					m.NameMod = null;
					m.RemoveItem(this);
					m.EquipItem(this);
					if( m.Kills >= 5)
					{
						m.Criminal = true;
					}
					if(m.GuildTitle != null)
					{
						m.DisplayGuildTitle = true;
					}
				}
				else if ( ItemID == 0x204F || ItemID == 0x1F03 )
				{
					m.SendMessage( "YOU ARE NOW PUBLIC STAFF." );
					m.PlaySound( 0x57 );
					ItemID = 0x204F;
					m.NameMod = "Counselor Defiance";
					m.DisplayGuildTitle = true;
					m.Criminal = false;
					m.RemoveItem(this);
					m.EquipItem(this);
				}
			}
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:38,代码来源:CNSDress.cs

示例8: OnDoubleClick

		public override void OnDoubleClick( Mobile m )
		{
			if( Parent != m )
			{
				m.SendMessage( "You must be wearing the robe to use it!" );
			}
			else
			{
				if ( ItemID == 0x204F || ItemID == 0x204F )
				{
					m.SendMessage( "YOU ARE NOW PRIVATE." );
					m.PlaySound( 0x57 );
					ItemID = 0x1F03;
					m.NameMod = null;
					m.RemoveItem(this);
					m.EquipItem(this);
					if( m.Kills >= 5)
					{
						m.Criminal = true;
					}
					if( m.GuildTitle != null)
					{
						m.DisplayGuildTitle = true;
					}
				}
				else if ( ItemID == 0x204F || ItemID == 0x1F03 )
				{
					m.SendMessage( "YOU ARE NOW PUBLIC STAFF." );
					m.PlaySound( 0x57 );
					ItemID = 0x204F;
					m.NameMod = "Trial Defiance";
					m.DisplayGuildTitle = true;
					m.Criminal = false;
					m.RemoveItem(this);
					m.EquipItem(this);
				}
			}
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:38,代码来源:TRLDress.cs

示例9: From

        public static void From(Mobile m)
        {
            if (m.Backpack == null || !m.Alive)
                return;

            int key = m.Serial.Value;

            if (Config.AllowPlayerToggle && DisabledPlayers.Contains(key))
                return;

            Item weapon = m.FindItemOnLayer(Layer.OneHanded);

            if (weapon == null || !weapon.Movable)
                weapon = m.FindItemOnLayer(Layer.TwoHanded);

            Item lastWeapon = null;

            if (PlayerWeapons.ContainsKey(key))
                lastWeapon = PlayerWeapons[key];

            if (m.Warmode)
            {
                if ((weapon == null || AllowedToKeep(weapon)) && lastWeapon != null && lastWeapon.IsChildOf(m.Backpack) && lastWeapon.Movable && lastWeapon.Visible && !lastWeapon.Deleted)
                {
                    m.EquipItem(lastWeapon);

                    if (Config.SendOverheadMessage)
                        m.LocalOverheadMessage(MessageType.Emote, m.EmoteHue, false, "*Unsheathes Weapon*");
                }
            }
            else
            {
                if (weapon != null && !AllowedToKeep(weapon))
                {
                    m.Backpack.DropItem(weapon);
                    PlayerWeapons[key] = weapon;

                    if (Config.SendOverheadMessage)
                        m.LocalOverheadMessage(MessageType.Emote, m.EmoteHue, false, "*Sheathes Weapon*");
                }
            }
        }
开发者ID:Vorpalstar,项目名称:runuo-custom-scripts,代码行数:42,代码来源:AutoSheatheWeapon.cs

示例10: GiveItem

        public static void GiveItem( Mobile m, Item item )
        {
            if ( item is BaseArmor )
                ((BaseArmor)item).Quality = ArmorQuality.Exceptional;
            else if ( item is BaseWeapon )
                ((BaseWeapon)item).Quality = WeaponQuality.Exceptional;

            Item move = m.FindItemOnLayer( item.Layer );
            if ( move != null )
            {
                if ( !m.PlaceInBackpack( move ) )
                {
                    item.Delete();
                    return;
                }
            }

            if ( !m.EquipItem( item ) && !m.PlaceInBackpack( item ) )
                item.Delete();
        }
开发者ID:cynricthehun,项目名称:UOLegends,代码行数:20,代码来源:AutoSupply.cs

示例11: EquipInsularii

        public static void EquipInsularii(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            switch (a)
            {
                case Armament.Light:
                    {
                        MaleDress dress = new MaleDress();
                        dress.Name = "A Ceremonial Robe";
                        dress.Layer = Layer.InnerTorso;
                        dress.Hue = 2990;

                        PlateArms arms = new PlateArms();
                        arms.Resource = CraftResource.Bronze;
                        arms.Hue = 2990;

                        ElegantDoublet doub = new ElegantDoublet();
                        doub.Name = "A Ceremonial Tunic";
                        doub.Hue = 2707;

                        KhemetarRogueTurban gorget = new KhemetarRogueTurban();
                        gorget.Hue = 2990;

                        PlateGloves gloves = new PlateGloves();
                        gloves.Resource = CraftResource.Bronze;
                        gloves.Hue = 2990;

                        HardenedThighBoots boots = new HardenedThighBoots();
                        boots.Resource = CraftResource.BeastLeather;
                        boots.Hue = 2990;

                        BeltPouch belt = new BeltPouch();
                        belt.Hue = 2990;

                        FancyGlasses glasses = new FancyGlasses();
                        glasses.Hue = 2707;

                        m.EquipItem(dress);
                        m.EquipItem(arms);
                        m.EquipItem(doub);
                        m.EquipItem(gorget);
                        m.EquipItem(gloves);
                        m.EquipItem(boots);
                        m.EquipItem(belt);
                        m.EquipItem(glasses);

                        Shortsword ss = new Shortsword();
                        ss.Resource = CraftResource.Iron;
                        m.EquipItem(ss);

                        Buckler shield = new Buckler();
                        shield.Resource = CraftResource.Bronze;
                        shield.Hue = 2707;
                        m.EquipItem(shield);

                        break;
                    }
                case Armament.Medium:
                    {
                        MaleDress dress = new MaleDress();
                        dress.Name = "A Ceremonial Robe";
                        dress.Layer = Layer.InnerTorso;
                        dress.Hue = 2990;

                        PlateArms arms = new PlateArms();
                        arms.Resource = CraftResource.Bronze;
                        arms.Hue = 2990;

                        ElegantDoublet doub = new ElegantDoublet();
                        doub.Name = "A Ceremonial Tunic";
                        doub.ItemID = 15502;
                        doub.Hue = 2707;

                        KhemetarRogueTurban gorget = new KhemetarRogueTurban();
                        gorget.Layer = Layer.Neck;
                        gorget.Hue = 2990;

                        PlateGloves gloves = new PlateGloves();
                        gloves.Resource = CraftResource.Bronze;
                        gloves.Hue = 2990;

                        HardenedThighBoots boots = new HardenedThighBoots();
                        boots.Resource = CraftResource.BeastLeather;
                        boots.Hue = 2990;

                        TyreanHornedPlateHelm helm = new TyreanHornedPlateHelm();
                        helm.Resource = CraftResource.Bronze;
                        helm.Name = "A Horned Helmet";
                        helm.Hue = 2990;

                        BeltPouch belt = new BeltPouch();
                        belt.Hue = 2990;

                        FancyGlasses glasses = new FancyGlasses();
                        glasses.Hue = 2707;

//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:Soldier.cs

示例12: EquipImperial

        public static void EquipImperial(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            Surcoat coat = new Surcoat();
            coat.ItemID = 15476;
            coat.Name = "A Surcoat of the Imperial Legion";
            coat.Hue = 2751;
            m.EquipItem(coat);

            switch (a)
            {
                case Armament.Light:
                    {
                        LeatherBoots boots = new LeatherBoots();
                        boots.Resource = CraftResource.BeastLeather;
                        boots.Hue = 1899;
                        m.EquipItem(boots);

                        WolfMask mask = new WolfMask();
                        mask.Hue = 1899;
                        m.EquipItem(mask);

                        StuddedChest sc = new StuddedChest();
                        sc.Resource = CraftResource.BeastLeather;
                        sc.Hue = 1899;
                        m.EquipItem(sc);

                        StuddedLegs sl = new StuddedLegs();
                        sl.Resource = CraftResource.BeastLeather;
                        sl.Hue = 1899;
                        m.EquipItem(sl);

                        StuddedArms sa = new StuddedArms();
                        sa.Resource = CraftResource.BeastLeather;
                        sa.Hue = 1899;
                        m.EquipItem(sa);

                        StuddedGloves sg = new StuddedGloves();
                        sg.Resource = CraftResource.BeastLeather;
                        sg.Hue = 1899;
                        m.EquipItem(sg);

                        StuddedGorget so = new StuddedGorget();
                        so.Resource = CraftResource.BeastLeather;
                        so.Hue = 1899;
                        m.EquipItem(so);

                        VhalurianGladius vg = new VhalurianGladius();
                        vg.Resource = CraftResource.Iron;
                        vg.Hue = 0;
                        m.EquipItem(vg);

                        WoodenShield ws = new WoodenShield();
                        ws.Resource = CraftResource.Ash;
                        m.EquipItem(ws);

                        break;
                    }
                case Armament.Medium:
                    {
                        ChainChest cc = new ChainChest();
                        cc.Resource = CraftResource.Bronze;
                        cc.Hue = 1899;
                        m.EquipItem(cc);

                        ChainLegs cl = new ChainLegs();
                        cl.Resource = CraftResource.Bronze;
                        cl.Hue = 1899;
                        m.EquipItem(cl);

                        ChainCoif co = new ChainCoif();
                        co.Resource = CraftResource.Bronze;
                        co.Hue = 1899;
                        m.EquipItem(co);

                        RingmailArms ra = new RingmailArms();
                        ra.Resource = CraftResource.Bronze;
                        ra.Hue = 1899;
                        m.EquipItem(ra);

                        RingmailGloves rg = new RingmailGloves();
                        rg.Resource = CraftResource.Bronze;
                        rg.Hue = 1899;
                        m.EquipItem(rg);

                        TyreanKiteShield vmks = new TyreanKiteShield();
                        vmks.Resource = CraftResource.Bronze;
                        vmks.Hue = 1899;
                        m.EquipItem(vmks);

                        LeatherBoots boots = new LeatherBoots();
                        boots.Resource = CraftResource.BeastLeather;
                        boots.Hue = 1899;
                        m.EquipItem(boots);

                        TyreanOrnateAxe axe = new TyreanOrnateAxe();
//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:Soldier.cs

示例13: EquipFreeSoldier

        public static void EquipFreeSoldier(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            int chance = Utility.RandomMinMax(1, 6);
            Nation nation = Nation.Vhalurian;

            switch (chance)
            {
                case 1: nation = Nation.Alyrian; break;
                case 2: nation = Nation.Azhuran; break;
                case 3: nation = Nation.Khemetar; break;
                case 4: nation = Nation.Mhordul; break;
                case 5: nation = Nation.Tyrean; break;
                case 6: nation = Nation.Vhalurian; break;
            }

            m.Language = "Common";
            m.Female = Utility.RandomBool();

            if (m.Female)
            {
                m.Body = 0x191;
                (m as Soldier).BaseName = RandomName(nation, true) + RandomSurname(nation, true);
            }

            else
            {
                m.Body = 0x190;
                (m as Soldier).BaseName = BaseKhaerosMobile.RandomName(nation, false) + RandomSurname(nation, false);
            }

            m.Hue = BaseKhaerosMobile.AssignRacialHue(nation);
            m.HairItemID = BaseKhaerosMobile.AssignRacialHair(nation, m.Female);
            int hairhue = BaseKhaerosMobile.AssignRacialHairHue(nation);
            m.HairHue = hairhue;

            if (!m.Female)
            {
                m.FacialHairItemID = BaseKhaerosMobile.AssignRacialFacialHair(nation);
                m.FacialHairHue = hairhue;
            }
            else
                m.FacialHairItemID = 0;

            if (m.Backpack == null)
                m.AddItem(new Backpack());

            m.Name = ((m as Soldier).BaseName + " the Free Soldier");

            ChainChest cc = new ChainChest();
            m.EquipItem(cc);
            PlateArms pa = new PlateArms();
            m.EquipItem(pa);
            TyreanHalfPlateGloves thpg = new TyreanHalfPlateGloves();
            m.EquipItem(thpg);
            PlateGorget pg = new PlateGorget();
            m.EquipItem(pg);
            PlateLegs pl = new PlateLegs();
            m.EquipItem(pl);
            m.EquipItem(new Cloak(Utility.RandomMinMax(1873, 1908)));
            m.EquipItem(new Tunic(Utility.RandomMinMax(1873, 1908)));

            int RandomWeapons = Utility.Random(3);

            switch (RandomWeapons)
            {
                case 0: Broadsword sword = new Broadsword(); m.EquipItem(sword); MetalShield shield = new MetalShield(); m.EquipItem(shield); break;
                case 1: WarHammer wh = new WarHammer(); m.EquipItem(wh); break;
                case 2: Bow b = new Bow(); m.EquipItem(b); m.AddToBackpack(new Arrow(Utility.Random(20))); (m as BaseCreature).AI = AIType.AI_Archer; break;
            }
        }
开发者ID:justdanofficial,项目名称:khaeros,代码行数:75,代码来源:Soldier.cs

示例14: EquipAzhuran

        public static void EquipAzhuran(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            switch (a)
            {
                case Armament.Light:
                    {
                        Sandals sandals = new Sandals();
                        sandals.Resource = CraftResource.BeastLeather;
                        sandals.Hue = 2810;
                        m.EquipItem(sandals);

                        LeatherLegs ll = new LeatherLegs();
                        ll.Resource = CraftResource.ScaledLeather;
                        m.EquipItem(ll);

                        LeatherGloves lg = new LeatherGloves();
                        lg.Resource = CraftResource.ScaledLeather;
                        m.EquipItem(lg);

                        AzhuranJesterMask mask = new AzhuranJesterMask();
                        mask.Hue = 2810;
                        m.EquipItem(mask);

                        Shortsword sword = new Shortsword();
                        if (Utility.Random(100) + 1 > 99)
                            sword.Resource = CraftResource.Obsidian;
                        else
                            sword.Resource = CraftResource.Bronze;
                        m.EquipItem(sword);

                        BoiledLeatherShield shield = new BoiledLeatherShield();
                        shield.Resource = CraftResource.Ash;
                        m.EquipItem(shield);

                        break;
                    }
                case Armament.Medium:
                    {
                        AzhuranLeatherTunic chest = new AzhuranLeatherTunic();
                        chest.Resource = CraftResource.BeastLeather;

                        AzhuranLeatherPauldrons pauldrons = new AzhuranLeatherPauldrons();
                        pauldrons.Resource = CraftResource.BeastLeather;

                        AzhuranLeatherBoots boots = new AzhuranLeatherBoots();
                        boots.Resource = CraftResource.BeastLeather;

                        AzhuranLeatherLegs legs = new AzhuranLeatherLegs();
                        legs.Resource = CraftResource.BeastLeather;

                        LeatherGloves gloves = new LeatherGloves();
                        gloves.Resource = CraftResource.BeastLeather;

                        LeatherArms arms = new LeatherArms();
                        arms.Resource = CraftResource.BeastLeather;

                        AzhuranSpear spear = new AzhuranSpear();
                        spear.Resource = CraftResource.Bronze;

                        m.EquipItem(chest);
                        m.EquipItem(pauldrons);
                        m.EquipItem(new Bandana(2810));
                        m.EquipItem(spear);
                        m.EquipItem(boots);
                        m.EquipItem(legs);
                        m.EquipItem(gloves);
                        m.EquipItem(arms);
                        break;
                    }
                case Armament.Heavy:
                    {
                        AzhuranHelm helm = new AzhuranHelm();
                        helm.Resource = CraftResource.Bronze;

                        AzhuranSpikedChainChest chest = new AzhuranSpikedChainChest();
                        chest.Resource = CraftResource.Bronze;

                        RingmailArms arms = new RingmailArms();
                        arms.Resource = CraftResource.Bronze;

                        ChainLegs legs = new ChainLegs();
                        legs.Resource = CraftResource.Bronze;

                        RingmailGloves gloves = new RingmailGloves();
                        gloves.Resource = CraftResource.Bronze;

                        m.EquipItem(helm);
                        m.EquipItem(chest);
                        Sandals sandals = new Sandals();
                        sandals.Resource = CraftResource.BeastLeather;
                        sandals.Hue = 2810;
                        m.EquipItem(sandals);
                        m.EquipItem(gloves);
                        m.EquipItem(arms);
                        m.EquipItem(legs);
//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:Soldier.cs

示例15: EquipAlyrian

        public static void EquipAlyrian(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            switch (a)
            {
                case Armament.Light:
                    {
                        AlyrianClaymore sword = new AlyrianClaymore();
                        sword.Resource = CraftResource.Bronze;
                        m.EquipItem(sword);

                        StuddedChest chest = new StuddedChest();
                        chest.Resource = CraftResource.RegularLeather;
                        m.EquipItem(chest);

                        StuddedLegs legs = new StuddedLegs();
                        legs.Resource = CraftResource.RegularLeather;
                        m.EquipItem(legs);

                        if (m.Female)
                        {
                            m.EquipItem(new ElegantFemaleKilt(2587));
                            m.EquipItem(new MetallicBra());
                            m.EquipItem(new ElegantShoes());
                        }
                        else
                        {
                            m.EquipItem(new OrnateKilt(2587));
                            m.EquipItem(new Sandals());
                        }

                        break;
                    }
                case Armament.Medium:
                    {
                        AlyrianRoundShield shield = new AlyrianRoundShield();
                        shield.Resource = CraftResource.Bronze;
                        m.EquipItem(shield);

                        AlyrianLongsword sword = new AlyrianLongsword();
                        sword.Resource = CraftResource.Bronze;
                        m.EquipItem(sword);

                        AlyrianChainChest chest = new AlyrianChainChest();
                        chest.Resource = CraftResource.Bronze;

                        AlyrianChainLegs legs = new AlyrianChainLegs();
                        legs.Resource = CraftResource.Bronze;

                        AlyrianChainArms arms = new AlyrianChainArms();
                        arms.Resource = CraftResource.Bronze;

                        AlyrianChainGorget gorget = new AlyrianChainGorget();
                        gorget.Resource = CraftResource.Bronze;

                        HardenedFurBoots boots = new HardenedFurBoots();

                        PlainKilt kilt = new PlainKilt(2587);
                        kilt.Resource = CraftResource.Wool;

                        Beret beret = new Beret(2587);
                        beret.Resource = CraftResource.Wool;

                        m.EquipItem(chest);
                        m.EquipItem(legs);
                        m.EquipItem(arms);
                        m.EquipItem(gorget);
                        m.EquipItem(boots);
                        m.EquipItem(kilt);
                        m.EquipItem(beret);

                        break;
                    }
                case Armament.Heavy:
                    {
                        AlyrianLeafShield shield = new AlyrianLeafShield();
                        shield.Resource = CraftResource.Bronze;
                        m.EquipItem(shield);

                        AlyrianSabre sabre = new AlyrianSabre();
                        sabre.Resource = CraftResource.Bronze;
                        m.EquipItem(sabre);

                        AlyrianChainChest chest = new AlyrianChainChest();
                        chest.Resource = CraftResource.Bronze;
                        m.EquipItem(chest);

                        PlateLegs legs = new PlateLegs();
                        legs.Resource = CraftResource.Bronze;
                        m.EquipItem(legs);

                        PlateArms arms = new PlateArms();
                        arms.Resource = CraftResource.Bronze;
                        m.EquipItem(arms);

                        PlateGorget gorget = new PlateGorget();
//.........这里部分代码省略.........
开发者ID:justdanofficial,项目名称:khaeros,代码行数:101,代码来源:Soldier.cs


注:本文中的Server.Mobile.EquipItem方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。