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


C# Container.GetWorldLocation方法代码示例

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


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

示例1: 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

示例2: 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

示例3: 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

示例4: 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 == "Cavern of the Discarded")
            {
                c.DropItem(new ReflectiveWolfEye());
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:10,代码来源:ClanSSW.cs

示例5: 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 == "Abyssal Lair Entrance")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssenceAchievement());
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:11,代码来源:GreaterMongbat.cs

示例6: 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 == "The Lands of the Lich")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssenceDirection());
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:11,代码来源:Shade.cs

示例7: 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 == "Passage of Tears")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssenceSingularity());

            }
        }
开发者ID:Ziden,项目名称:ServUO-EC-Test-Fork,代码行数:12,代码来源:InterredGrizzle+.cs

示例8: 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 == "Skeletal Dragon")
            {
                if (Utility.RandomDouble() < 0.6)
                    c.DropItem(new EssencePersistence());

            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:12,代码来源:PatchworkSkeleton.cs

示例9: 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 == "Passage of Tears")
            {
                switch (Utility.Random(2))
                {
                    case 0: c.DropItem(new EssenceSingularity()); break;
                    case 1: c.DropItem(new VialOfVitriol()); break;

                }
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:15,代码来源:AcidSlug.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 == "The Secret Gardens")
     {
         switch (Utility.Random(2))
         {
             case 0: c.DropItem(new EssenceFeeling()); break;
             case 1: c.DropItem(new FaeryDust()); break;
         }
         #region Mondain's Legacy
         if (Utility.RandomDouble() < 0.3)
             c.DropItem(new PixieLeg());
         #endregion
     }
 }
开发者ID:Ziden,项目名称:ServUO-EC-Test-Fork,代码行数:17,代码来源:SAPixie.cs

示例11: Container_Snoop

		public static void Container_Snoop( Container cont, Mobile from )
		{

            if (from.BeginAction(typeof(IAction)))
            {
                bool releaseLock = true;
                bool canSnoop = true;

                if (from.AccessLevel > AccessLevel.Player || from.InRange(cont.GetWorldLocation(), 1))
                {
                    Mobile root = cont.RootParent as Mobile;

                    if (root != null && !root.Alive)
                        canSnoop = false;
                    else if (root != null && root.AccessLevel > AccessLevel.Player && from.AccessLevel == AccessLevel.Player)
                    {
                        from.SendLocalizedMessage(500209); // You can not peek into the container.
                        canSnoop = false;
                    }
                    else if (root != null && from.AccessLevel == AccessLevel.Player && !CheckSnoopAllowed(from, root))
                    {
                        from.SendLocalizedMessage(1001018); // You cannot perform negative acts on your target.
                        canSnoop = false;
                    }

                    if (canSnoop)
                    {
                        if (from.AccessLevel > AccessLevel.Player)
                            cont.DisplayTo(from);
                        else
                        {
                            new InternalTimer(from, cont).Start();
                            releaseLock = false;
                        }
                    }
                }
                else
                    from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1019045); // I can't reach that.

                if (releaseLock && from is PlayerMobile)
                    ((PlayerMobile)from).EndPlayerAction();
            }
            else
                from.SendAsciiMessage("You must wait to perform another action.");
		}
开发者ID:FreeReign,项目名称:imaginenation,代码行数:45,代码来源:Snooping.cs

示例12: 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 == "Crimson Veins")
			{
				if (Utility.RandomDouble() < 0.6)
				{
					switch (Utility.Random(2))
					{
						case 0: c.DropItem(new EssencePrecision()); break;
						case 1: c.DropItem(new LavaSerpentCrust()); break;
					}
				}
			}

			if (0.25 > Utility.RandomDouble() && reg.Name == "Fire Temple Ruins")
			{
				if (Utility.RandomDouble() < 0.6)
				{
					switch (Utility.Random(2))
					{
						case 0: c.DropItem(new EssenceOrder()); break;
						case 1: c.DropItem(new LavaSerpentCrust()); break;
					}
				}
			}
			if (0.25 > Utility.RandomDouble() && reg.Name == "Lava Caldera")
			{
				if (Utility.RandomDouble() < 0.6)
				{
					switch (Utility.Random(2))
					{
						case 0: c.DropItem(new EssencePassion()); break;
						case 1: c.DropItem(new LavaSerpentCrust()); break;
					}
				}
			}
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:40,代码来源:LavaElemental.cs

示例13: 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 == "Cavern of the Discarded")
            {
                switch (Utility.Random(10))
                {
                    case 0: c.DropItem(new AbyssalCloth()); break;
                    case 1: c.DropItem(new PowderedIron()); break;
                    case 2: c.DropItem(new CrystallineBlackrock()); break;
                    case 3: c.DropItem(new EssenceBalance()); break;
                    case 4: c.DropItem(new CrystalShards()); break;
                    case 5: c.DropItem(new ArcanicRuneStone()); break;
                    case 6: c.DropItem(new DelicateScales()); break;
                    case 7: c.DropItem(new SeedRenewal()); break;
                    case 8: c.DropItem(new CrushedGlass()); break;
                    case 9: c.DropItem(new ElvenFletchings()); break;
                }
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:22,代码来源:ClanSS.cs

示例14: 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 == "Enslaved Goblins")
            {
                switch (Utility.Random(2))
                {
                    case 0: c.DropItem(new EssenceControl()); break;
                    case 1: c.DropItem(new GoblinBlood()); break;

                }
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:15,代码来源:EnslavedGoblinKeeper.cs

示例15: GetSADrop

        public static void GetSADrop(Container c)
        {
            if (Utility.RandomDouble() <= 0.90) // 10% chance to move forward and drop 
                return;

            var reg = Region.Find(c.GetWorldLocation(), c.Map);

            if (reg == null || reg.Name == null)
                return;
            
            var regionname = reg.Name;

            switch (regionname)
            {
                case "Crimson Veins":
                {
                    c.DropItem(new EssencePrecision());
                    break;
                }
                case "Fire Temple Ruins":
                {
                    c.DropItem(new EssenceOrder());
                    break;
                }
                case "Lava Caldera":
                {
                    c.DropItem(new EssencePassion());
                    break;
                }
                case "Secret Garden":
                {
                    switch (Utility.Random(2))
                    {
                        case 0:
                            c.DropItem(new EssenceFeeling());
                            break;
                        case 1:
                            c.DropItem(new FaeryDust());
                            break;
                    }
                    break;
                }
                case "Cavern of the Discarded":
                {
                    switch (Utility.Random(12))
                    {
                        case 0:
                            c.DropItem(new AbyssalCloth());
                            break;
                        case 1:
                            c.DropItem(new PowderedIron());
                            break;
                        case 2:
                            c.DropItem(new CrystallineBlackrock());
                            break;
                        case 3:
                            c.DropItem(new EssenceBalance());
                            break;
                        case 4:
                            c.DropItem(new CrystalShards());
                            break;
                        case 5:
                            c.DropItem(new ArcanicRuneStone());
                            break;
                        case 6:
                            c.DropItem(new DelicateScales());
                            break;
                        case 7:
                            c.DropItem(new SeedRenewal());
                            break;
                        case 8:
                            c.DropItem(new CrushedGlass());
                            break;
                        case 9:
                            c.DropItem(new ElvenFletchings());
                            break;
                        case 10:
                            c.DropItem(new Lodestone());
                            break;
                        case 11:
                            c.DropItem(new ReflectiveWolfEye());
                            break;
                    }
                    break;
                }
                case "Abyssal Lair":
                {
                    c.DropItem(new EssenceAchievement());
                    break;
                }
                case "StygianDragonLair":
                {
                    c.DropItem(new EssenceDiligence());
                    break;
                }
                case "Skeletal Dragon":
                {
                    c.DropItem(new EssencePersistence());
                    break;
                }
//.........这里部分代码省略.........
开发者ID:Crome696,项目名称:ServUO,代码行数:101,代码来源:SARegionDrops.cs


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