Example #1
0
        public override void OnBeforeSpawn(Point3D location, Map m)
        {
            Notify.Broadcast <HydraMotMNotifyGump>(
                "The Monster of the Month, the Hydra, has spawned.[br]A moongate to his watery lair has been conjured at Britain bank.",
                true,
                1.0,
                10.0);

            _Moongate = new ExtEventMoongate(new Point3D(5997, 1473, 0), Map.Felucca)
            {
                Dispellable = false,
                Hue         = 1259,
                Name        = "To the Lair of the Hydra"
            };

            _Moongate.MoveToWorld(new Point3D(1411, 1716, 40), Map.Felucca);

            GlobalTownCrierEntryList.Instance.AddEntry(
                new[]
            {
                "Adventurers are needed! The Hydra has awakened in his watery lair!",
                "Please use the moongate located to the west of Britain bank and help vanquish this fiend!"
            },
                TimeSpan.FromMinutes(60));

            base.OnBeforeSpawn(location, m);
        }
Example #2
0
        public virtual void OnWorldFirst(ConquestState s)
        {
            if (!Enabled || Deleted || s == null || s.Conquest != this || s.User == null)
            {
                return;
            }

            if (SoundOnWorldFirst > 0)
            {
                s.User.PlaySound(SoundOnWorldFirst);
            }

            var msg = new StringBuilder();

            msg.AppendLine("World First Conquest!".WrapUOHtmlTag("big"));
            msg.AppendLine("\"{0}\"", Name.WrapUOHtmlColor(Color));
            msg.AppendLine("Unlocked by {0}", s.User.RawName.WrapUOHtmlColor(s.User.GetNotorietyColor()));

            string text = msg.ToString().WrapUOHtmlColor(KnownColor.White);

            if (!Conquests.CMOptions.SupressWorldFirsts)
            {
                Notify.Broadcast <ConquestNotifyGump>(text, true, 1.0, 10.0);
            }

            if (Conquests.CMOptions.ModuleDebug)
            {
                Conquests.CMOptions.ToConsole("{0} world first: {1}", Name, s.User, s.Tier);
            }
        }
Example #3
0
        public void RestartInvasion()
        {
            CurrentLevel = Levels.First();
            Invaders.Clear();
            Invaders.TrimExcess();
            CurrentLevelKills = 0;
            _CoreTicks        = 0;
            DateStarted       = DateTime.UtcNow;
            ParticipantsScores.Clear();
            SpawnInvaders(CurrentLevel.SpawnAmount);
            Status = InvasionStatus.Running;
            Notify.Broadcast <HydraMotMNotifyGump>(
                "The " + InvasionName + " has begun!",
                true,
                1.0,
                10.0);

            init();
        }
Example #4
0
 public void FinishInvasion()
 {
     Status = InvasionStatus.Finished;
     _CoreTimer.Stop();
     RemoveInvaders();
     if (ValidSpawnPoints != null)
     {
         ValidSpawnPoints.Clear();
         ValidSpawnPoints.TrimExcess();
     }
     if (TownGates != null)
     {
         DeleteGates();
     }
     Notify.Broadcast <HydraMotMNotifyGump>(
         "The " + InvasionName + " has ended!",
         true,
         1.0,
         10.0);
     GenerateScoreboards();
     CurrentLevel = Levels.First();
 }