示例#1
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);
            int version = reader.ReadInt();

            Troll         = reader.ReadMobile() as CaveTroll;
            StartSpot     = reader.ReadPoint3D();
            StartMap      = reader.ReadMap();
            TrollSpawnLoc = reader.ReadPoint3D();

            if (Troll != null)
            {
                Troll.Wall = this;
            }

            if (Location != StartSpot || Troll == null || Troll.Deleted || !Troll.Alive)
            {
                Reset();
            }

            if (version == 2)
            {
                Timer.DelayCall(() => AddTeleporters(this));
            }

            if (version == 1 && StartSpot == new Point3D(5619, 57, 0) && StartMap == Map.Felucca)
            {
                Timer.DelayCall(TimeSpan.FromSeconds(20), () =>
                {
                    ShameWall.AddTeleporters(this);
                });
            }
        }
示例#2
0
        public static void AddTeleporters(ShameWall wall)
        {
            Map map = wall.Map;

            if (map == null || map == Map.Internal)
            {
                return;
            }

            foreach (AddonComponent component in wall.Components)
            {
                foreach (Point3D[] pnts in _TeleportLocs)
                {
                    if (component.Location == pnts[0])
                    {
                        ConditionTeleporter oldtele = map.FindItem <ConditionTeleporter>(new Point3D(pnts[1]));

                        if (oldtele != null)
                        {
                            WeakEntityCollection.Remove("newshame", oldtele);
                            oldtele.Delete();
                        }

                        ShameWallTeleporter teleporter = new ShameWallTeleporter(pnts[2], map);
                        teleporter.MoveToWorld(pnts[1], map);

                        WeakEntityCollection.Add("newshame", teleporter);
                    }
                }
            }
        }
示例#3
0
        public static void AddTeleporters(ShameWall wall)
        {
            Map map = wall.Map;

            if (map == null || map == Map.Internal)
            {
                return;
            }

            for (var index = 0; index < wall.Components.Count; index++)
            {
                AddonComponent component = wall.Components[index];

                for (var i = 0; i < _TeleportLocs.Length; i++)
                {
                    Point3D[] pnts = _TeleportLocs[i];

                    if (component.Location == pnts[0])
                    {
                        ConditionTeleporter oldtele = map.FindItem <ConditionTeleporter>(new Point3D(pnts[1]));

                        if (oldtele != null)
                        {
                            WeakEntityCollection.Remove("newshame", oldtele);
                            oldtele.Delete();
                        }

                        ShameWallTeleporter teleporter = new ShameWallTeleporter(pnts[2], map);
                        teleporter.MoveToWorld(pnts[1], map);

                        WeakEntityCollection.Add("newshame", teleporter);
                    }
                }
            }
        }
示例#4
0
        public static void AddTeleporters(ShameWall wall)
        {
            Map map = wall.Map;

            if (map == null || map == Map.Internal)
            {
                return;
            }

            foreach (var component in wall.Components)
            {
                foreach (Point3D[] pnts in _TeleportLocs)
                {
                    if (component.Location == pnts[0])
                    {
                        var teleporter = new ConditionTeleporter();
                        //teleporter.DeadOnly = true;
                        teleporter.ClilocNumber   = 1072790; // The wall becomes transparent, and you push your way through it.
                        teleporter.MapDest        = map;
                        teleporter.PointDest      = pnts[2];
                        teleporter.DisableMessage = false;
                        teleporter.MoveToWorld(pnts[1], map);
                        WeakEntityCollection.Add("newshame", teleporter);
                    }
                }
            }
        }
示例#5
0
        public static void AddTeleporters(ShameWall wall)
        {
            Map map = wall.Map;

            if (map == null || map == Map.Internal)
            {
                return;
            }

            foreach (var component in wall.Components)
            {
                foreach (Point3D[] pnts in _TeleportLocs)
                {
                    if (component.Location == pnts[0])
                    {
                        var teleporter = new ConditionTeleporter();
                        teleporter.DeadOnly       = true;
                        teleporter.MapDest        = map;
                        teleporter.PointDest      = pnts[2];
                        teleporter.DisableMessage = true;
                        teleporter.MoveToWorld(pnts[1], map);
                        WeakEntityCollection.Add("newshame", teleporter);
                    }
                }
            }
        }
示例#6
0
        public static void Generate(CommandEventArgs e)
        {
            RemoveItems();

            CommandSystem.Handle(e.Mobile, CommandSystem.Prefix + "XmlLoad RevampedSpawns/ShameRevamped.xml");

            // Level 1
            Point3D altarLoc = new Point3D(5403, 43, 30);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                ShameAltar altar = new ShameAltar(typeof(QuartzElemental), new Point3D(5490, 19, -25), new Point3D(5514, 10, 5), new Point3D(5387, 11, 30), 10);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                ShameAltar altar = new ShameAltar(typeof(QuartzElemental), new Point3D(5490, 19, -25), new Point3D(5514, 10, 5), new Point3D(5387, 11, 30), 10);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Level 2
            altarLoc = new Point3D(5577, 54, 2);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                ShameAltar altar = new ShameAltar(typeof(FlameElemental), new Point3D(5604, 102, 5), new Point3D(5514, 147, 25), new Point3D(5571, 115, 3), 20);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                ShameAltar altar = new ShameAltar(typeof(FlameElemental), new Point3D(5604, 102, 5), new Point3D(5514, 147, 25), new Point3D(5571, 115, 3), 20);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Level 3
            altarLoc = new Point3D(5390, 145, 20);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                ShameAltar altar = new ShameAltar(typeof(WindElemental), new Point3D(5538, 170, 5), new Point3D(5513, 176, 5), new Point3D(5618, 223, 0), 30);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                ShameAltar altar = new ShameAltar(typeof(WindElemental), new Point3D(5538, 170, 5), new Point3D(5513, 176, 5), new Point3D(5618, 223, 0), 30);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Wall 1
            Dictionary <Point3D, int> dictionary = null;

            altarLoc = new Point3D(5403, 82, 10);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)]  = 2272;
                dictionary[new Point3D(2, 0, 0)]  = 2272;
                dictionary[new Point3D(1, 0, 0)]  = 2272;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5405, 90, 10), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
                ShameWall.AddTeleporters(wall);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)]  = 2272;
                dictionary[new Point3D(2, 0, 0)]  = 2272;
                dictionary[new Point3D(1, 0, 0)]  = 2272;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5405, 90, 10), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
                ShameWall.AddTeleporters(wall);
            }

            // Wall 2
            altarLoc = new Point3D(5465, 26, -10);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(0, -1, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)]  = 2272;
                dictionary[new Point3D(0, 1, 0)]  = 2272;
                dictionary[new Point3D(0, 2, 0)]  = 2272;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5472, 26, -30), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
                ShameWall.AddTeleporters(wall);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(0, -1, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)]  = 2272;
                dictionary[new Point3D(0, 1, 0)]  = 2272;
                dictionary[new Point3D(0, 2, 0)]  = 2272;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5472, 26, -30), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
                ShameWall.AddTeleporters(wall);
            }

            // Wall 3
            altarLoc = new Point3D(5619, 57, 0);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 1059;
                dictionary[new Point3D(0, 0, 0)]  = 1059;
                dictionary[new Point3D(1, 0, 0)]  = 1059;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5621, 43, 0), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
                ShameWall.AddTeleporters(wall);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary <Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 1059;
                dictionary[new Point3D(0, 0, 0)]  = 1059;
                dictionary[new Point3D(1, 0, 0)]  = 1059;

                ShameWall wall = new ShameWall(dictionary, altarLoc, new Point3D(5621, 43, 0), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
                ShameWall.AddTeleporters(wall);
            }

            e.Mobile.SendMessage("Shame Revamped setup!");
        }
示例#7
0
        public CaveTroll(ShameWall wall)
		{
			Name = "a cave troll";
            BodyValue = 0x1;
            FightMode = FightMode.Aggressor;

			if(wall != null)
				Title = "the wall guardian";

            Hue = 2016;
			Wall = wall;

			SetStr( 180, 210 );
			SetDex( 120, 150 );
			SetInt( 40, 70 );

			SetHits( 700, 900 );

			SetDamage( 15, 17 );

			SetDamageType( ResistanceType.Physical, 100 );

			SetResistance( ResistanceType.Physical, 55, 65 );
			SetResistance( ResistanceType.Fire, 45, 55 );
			SetResistance( ResistanceType.Cold, 45, 55 );
			SetResistance( ResistanceType.Poison, 35, 45 );
			SetResistance( ResistanceType.Energy, 35, 45 );

			SetSkill( SkillName.MagicResist, 70, 90 );
			SetSkill( SkillName.Tactics, 80, 110 );
			SetSkill( SkillName.Wrestling, 80, 110 );

			Fame = 3500;
			Karma = -3500;
			
			//PackItem(new Potash(Utility.RandomMinMax(1, 5)));
			//PackItem(new Charcoal(Utility.RandomMinMax(1, 5)));
			//PackItem(new Saltpeter(Utility.RandomMinMax(1, 5)));
            //PackItem(new BlackPowder(Utility.RandomMinMax(1, 5)));
			PackGem(1);
		}
示例#8
0
        public static void Generate(CommandEventArgs e)
        {
            RemoveItems();

            // Level 1
            Point3D altarLoc = new Point3D(5403, 43, 30);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                var altar = new ShameAltar(typeof(QuartzElemental), new Point3D(5490, 19, -25), new Point3D(5514, 10, 5), new Point3D(5387, 11, 30), 10);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                var altar = new ShameAltar(typeof(QuartzElemental), new Point3D(5490, 19, -25), new Point3D(5514, 10, 5), new Point3D(5387, 11, 30), 10);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Level 2
            altarLoc = new Point3D(5577, 54, 2);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                var altar = new ShameAltar(typeof(FlameElemental), new Point3D(5604, 102, 5), new Point3D(5514, 147, 25), new Point3D(5571, 115, 3), 20);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                var altar = new ShameAltar(typeof(FlameElemental), new Point3D(5604, 102, 5), new Point3D(5514, 147, 25), new Point3D(5571, 115, 3), 20);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Level 3
            altarLoc = new Point3D(5390, 145, 20);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                var altar = new ShameAltar(typeof(WindElemental), new Point3D(5538, 170, 5), new Point3D(5513, 176, 5), new Point3D(5618, 223, 0), 30);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                var altar = new ShameAltar(typeof(WindElemental), new Point3D(5538, 170, 5), new Point3D(5513, 176, 5), new Point3D(5618, 223, 0), 30);
                WeakEntityCollection.Add("newshame", altar);
                altar.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Wall 1
            Dictionary<Point3D, int> dictionary = null;
            altarLoc = new Point3D(5403, 82, 10);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)] = 2272;
                dictionary[new Point3D(2, 0, 0)] = 2272;
                dictionary[new Point3D(1, 0, 0)] = 2272;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5405, 90, 10), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)] = 2272;
                dictionary[new Point3D(2, 0, 0)] = 2272;
                dictionary[new Point3D(1, 0, 0)] = 2272;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5405, 90, 10), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Wall 2
            altarLoc = new Point3D(5465, 26, -10);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(0, -1, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)] = 2272;
                dictionary[new Point3D(0, 1, 0)] = 2272;
                dictionary[new Point3D(0, 2, 0)] = 2272;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5472, 26, -30), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(0, -1, 0)] = 2272;
                dictionary[new Point3D(0, 0, 0)] = 2272;
                dictionary[new Point3D(0, 1, 0)] = 2272;
                dictionary[new Point3D(0, 2, 0)] = 2272;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5472, 26, -30), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
            }

            // Wall 3
            altarLoc = new Point3D(5619, 57, 0);

            if (!CheckForAltar(altarLoc, Map.Trammel))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 1059;
                dictionary[new Point3D(0, 0, 0)] = 1059;
                dictionary[new Point3D(1, 0, 0)] = 1059;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5621, 43, 0), Map.Trammel);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Trammel);
            }

            if (!CheckForAltar(altarLoc, Map.Felucca))
            {
                dictionary = new Dictionary<Point3D, int>();
                dictionary[new Point3D(-1, 0, 0)] = 1059;
                dictionary[new Point3D(0, 0, 0)] = 1059;
                dictionary[new Point3D(1, 0, 0)] = 1059;

                var wall = new ShameWall(dictionary, altarLoc, new Point3D(5621, 43, 0), Map.Felucca);
                WeakEntityCollection.Add("newshame", wall);
                wall.MoveToWorld(altarLoc, Map.Felucca);
            }

            e.Mobile.SendMessage("Shame Revamped setup! Don't forget to setup the spawners!");
        }