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


C# Container.DropItem方法代码示例

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


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

示例1: OnDeath

        public override void OnDeath(Container c)
        {
            if (Utility.RandomDouble() <= 0.1)
            {
                c.DropItem(new BlindingAnkh());
            }

            if (Utility.RandomDouble() <= 0.01)
            {
                c.DropItem(new DaemonBlood{Hue = 33, Name = "Daemon Ichor"});
            }

            if (Utility.RandomDouble() <= 0.001)
            {
                if (Utility.RandomBool())
                {
                    c.DropItem(new BloodSpear {Hue = 33});
                }
                else
                {
                    c.DropItem(new BloodFork { Hue = 33 });
                }
            }
            base.OnDeath(c);
        }
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:25,代码来源:AsylumGuardian.cs

示例2: OnDeath

        public override void OnDeath(Container c)
        {

            base.OnDeath(c);
            Region reg = Region.Find(c.GetWorldLocation(), c.Map);
            if (1.0 > Utility.RandomDouble() && reg.Name == "Crimson Veins")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssencePrecision());
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new DaemonClaw());
            }

            if (1.0 > Utility.RandomDouble() && reg.Name == "Fire Temple Ruins")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssenceOrder());
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new DaemonClaw());
            }
            if (1.0 > Utility.RandomDouble() && reg.Name == "Lava Caldera")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssencePassion());
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new DaemonClaw());
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:28,代码来源:FireDaemon.cs

示例3: OnDeath

		public override void OnDeath( Container c )
		{
			base.OnDeath( c );	
			
			c.DropItem( new EyeOfTheTravesty() );
			c.DropItem( new OrdersFromMinax() );
			
			switch ( Utility.Random( 3 ) )
			{
				case 0: c.DropItem( new TravestysSushiPreparations() ); break;
				case 1: c.DropItem( new TravestysFineTeakwoodTray() ); break;
				case 2: c.DropItem( new TravestysCollectionOfShells() ); break;
			}
			
			if ( Utility.RandomDouble() < 0.6 )				
				c.DropItem( new ParrotItem() );
			
			if ( Utility.RandomDouble() < 0.1 )
				c.DropItem( new TragicRemainsOfTravesty() );
				
			if ( Utility.RandomDouble() < 0.05 )
				c.DropItem( new ImprisonedDog() );
				
			if ( Utility.RandomDouble() < 0.05 )
				c.DropItem( new MarkOfTravesty() );
				
			if ( Utility.RandomDouble() < 0.025 )
				c.DropItem( new CrimsonCincture() );
		}
开发者ID:brodock,项目名称:genova-project,代码行数:29,代码来源:Travesty.cs

示例4: OnDeath

        public override void OnDeath(Container c)
        {
            base.OnDeath(c);

            if (Utility.RandomDouble() < 0.10)
            {
                switch (Utility.Random(2))
                {
                    case 0: c.DropItem(new EssenceDiligence()); break;

                    case 1: c.DropItem(new FairyDragonWing()); break;
                }

                if (Utility.RandomDouble() < 0.10)
                {
                    switch (Utility.Random(2))
                    {
                        case 0: c.DropItem(new DraconicOrbKey()); break;

                        case 1: c.DropItem(new UntransTome()); break;
                    }
                }

                if (Utility.RandomDouble() < 0.05)
                {
                   
                        c.DropItem(new AnimatedLegsoftheInsaneTinker()); 
                }
            }
        }
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:30,代码来源:WyvernR.cs

示例5: OnDeath

        public override void OnDeath(Container c)
        {
            base.OnDeath(c);

            c.DropItem(new DragonBlood(6));
            c.DropItem(new GargishStoneArms());
        }
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:7,代码来源:KepetchAmbusher.cs

示例6: Fill

		public static void Fill( Container c, int itemCount, double talismanChance )
		{
			c.Hue = Utility.RandomNondyedHue();

			int done = 0;

			if ( Utility.RandomDouble() < talismanChance )
			{
				c.DropItem( new RandomTalisman() );
				++done;
			}

			for ( ; done < itemCount; ++done )
			{
				Item loot = null;

				switch ( Utility.Random( 5 ) )
				{
					case 0: loot = Loot.RandomWeapon( false, true ); break;
					case 1: loot = Loot.RandomArmor( false, true ); break;
					case 2: loot = Loot.RandomRangedWeapon( false, true ); break;
					case 3: loot = Loot.RandomJewelry(); break;
					case 4: loot = Loot.RandomHat( false ); break;
				}

				if ( loot == null )
					continue;

				Enhance( loot );
				c.DropItem( loot );
			}
		}
开发者ID:nathanvy,项目名称:runuo,代码行数:32,代码来源:RewardBags.cs

示例7: OnDeath

		public override void OnDeath(Container c)
		{
			base.OnDeath(c);

			if (Utility.RandomDouble() < 0.20)
			{
				switch (Utility.Random(4))
				{
					case 0:
						c.DropItem(new EssenceDiligence());
						break;
					case 1:
						c.DropItem(new FairyDragonWing());
						break;
					case 2:
						c.DropItem(new FaeryDust());
						break;
					case 3:
						c.DropItem(new FeyWings());
						break;
				}

				if (Utility.RandomDouble() < 0.30)
				{
					c.DropItem(new DraconicOrbKeyBlue());
				}
			}
		}
开发者ID:RobBrown88,项目名称:ServUO,代码行数:28,代码来源:FairyDragon1.cs

示例8: OnDeath

		public override void OnDeath( Container c )
		{
			base.OnDeath( c );

            c.DropItem( new Gold(1500));
            c.DropItem( new Bandage(12));
        }
开发者ID:greeduomacro,项目名称:unknown-shard-1,代码行数:7,代码来源:RatLord.cs

示例9: OnDeath

		public override void OnDeath( Container c )
		{
			if ( Utility.Random( 35 ) < 1 )
			{
				DecemberDeed deed = new DecemberDeed();
				deed.Hue = 2006;
				deed.Name = "a deed from the Grinch";
				deed.Movable = true;
				deed.Weight = 5.0;
				c.DropItem( deed );
			}

            		int cnt = 1;
            		if ( Utility.Random( 4 ) < 1 ) cnt++;
            		if ( Utility.Random( 5 ) < 1 ) cnt++;

            		for (int i = 0; i < cnt; ++i)
            		{
                		switch (Utility.Random(4))
                		{
                    			case 0: c.DropItem( new SpecialHairDye() ); break;
                    			case 1: c.DropItem( new SpecialBeardDye() ); break;
                    			case 2: c.DropItem( new ClothingBlessDeed() ); break;
                    			case 3: c.DropItem( new NameChangeDeed() ); break;
                		}
            		}
			base.OnDeath( c );
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:28,代码来源:Grinch.cs

示例10: OnDeath

        public override void OnDeath(Container c)
        {

            base.OnDeath(c);
            Region reg = Region.Find(c.GetWorldLocation(), c.Map);
            if (0.25 > Utility.RandomDouble() && reg.Name == "Fairy Dragon Lair")
            {
                switch (Utility.Random(2))
                {
                    case 0: c.DropItem(new EssenceDiligence()); break;
                    case 1: c.DropItem(new FaeryDust()); break;
                }
            }
            if (Utility.RandomDouble() <= 0.25)
            {
                switch (Utility.Random(2))
                {
                    case 0:
                        c.DropItem(new FeyWings());
                        break;
                    case 1:
                        c.DropItem(new FairyDragonWing());
                        break;

                }
            }

            if (Utility.RandomDouble() < 0.10)
            {
                c.DropItem(new DraconicOrb());

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

示例11: OnDeath

        public override void OnDeath(Container c)
        {
            base.OnDeath(c);

            if (Utility.RandomDouble() < 0.05)
            {
                switch (Utility.Random(2))
                {
                    case 0:
                        c.DropItem(new SlithTongue());
                        break;
                    case 1:
                        c.DropItem(new SlithEye());
                        break;
                }
            }

            if (Utility.RandomDouble() < 0.25)
            {
                switch (Utility.Random(2))
                {
                    case 0:
                        c.DropItem(new AncientPotteryFragments());
                        break;
                    case 1:
                        c.DropItem(new TatteredAncientScroll());
                        break;
                }
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:30,代码来源:Slith.cs

示例12: OnDeath

		public override void OnDeath( Container c )
		{
			base.OnDeath( c );

			c.DropItem( new DiseasedBark() );
			c.DropItem( new EternallyCorruptTree() );

			int drop = Utility.Random( 2, 4 );

			for ( int i = 0; i < drop; i++ )
				c.DropItem( new MelisandesFermentedWine() );

			if ( Utility.RandomDouble() < 0.6 )
				c.DropItem( new ParrotItem() );

			if ( Utility.RandomDouble() < 0.2225 )
			{
				switch ( Utility.Random( 3 ) )
				{
					case 0: c.DropItem( new MelisandesHairDye() ); break;
					case 1: c.DropItem( new MelisandesCorrodedHatchet() ); break;
					case 2: c.DropItem( new AlbinoSquirrelImprisonedInCrystal() ); break;
				}
			}

			if ( Utility.RandomDouble() < 0.05 )
				c.DropItem( new MyrmidonLegs() );

			if ( Utility.RandomDouble() < 0.025 )
				c.DropItem( new CrimsonCincture() );
		}
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:31,代码来源:LadyMelisande.cs

示例13: OnDeath

 public override void OnDeath(Container c)
 {
     base.OnDeath(c);
     var reg = Region.Find(c.GetWorldLocation(), c.Map);
     if (0.4 > Utility.RandomDouble() && reg.Name == "Ariel Writ Disaster")
         c.DropItem(new ArielHavenWritofMembership());
     c.DropItem(new BonePile());
 }
开发者ID:rokann,项目名称:JustUO,代码行数:8,代码来源:RotWorm.cs

示例14: OnDeath

        public override void OnDeath(Container c)
        {
            base.OnDeath(c);	
			
                c.DropItem(new TigerClawKey());

            if (Utility.RandomDouble() < 0.5)
                c.DropItem(new TigerClawSectBadge());
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:9,代码来源:TigersClawMaster.cs

示例15: OnDeath

        public override void OnDeath(Container c)
        {
            base.OnDeath(c);

            c.DropItem(new SalivasFeather());

            if (Utility.RandomDouble() < 0.1)
                c.DropItem(new ParrotItem());
        }
开发者ID:rokann,项目名称:JustUO,代码行数:9,代码来源:Saliva.cs


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