Beispiel #1
0
        public static void AddMacroer(string[] lines, Mobile m, DateTime dt)
        {
            ListEntry le = new ListEntry(lines, m, dt, ListEntryType.PJUM);

            TCCS.AddEntry(le);
            PJUM.MakeAllEntriesCriminal();
        }
Beispiel #2
0
        public static ListEntry AddMacroer(string[] lines, Mobile m, DateTime dt)
        {
            ListEntry le = new ListEntry(lines, m, dt, ListEntryType.PJUM);

            TCCS.AddEntry(le);
            m.MakeCriminal(dt - DateTime.Now);
            return(le);
        }
Beispiel #3
0
        private void AutoShout_Callback()
        {
            TownCrierEntry tce = GetRandomEntry();

            if (Utility.RandomDouble() > 0.5 || tce == null)              //only spout off about macroers 1/2 the time
            {
                ListEntry le = TCCS.GetRandomEntry();
                if (le != null)
                {
                    tce = new TownCrierEntry(le.Lines, TimeSpan.FromMinutes(1), Serial.MinusOne);
                }
            }

            if (tce == null)
            {
                if (m_AutoShoutTimer != null)
                {
                    m_AutoShoutTimer.Stop();
                }

                m_AutoShoutTimer = null;
            }
            else if (m_NewsTimer == null)
            {
                m_NewsTimer = Timer.DelayCall(TimeSpan.FromSeconds(1.0), TimeSpan.FromSeconds(3.0), new TimerStateCallback(ShoutNews_Callback), new object[] { tce, 0 });

                // pla: 12/08/06
                // changed to show a different mesasge in a yellow hue for player messages
                Mobile m = World.FindMobile(tce.Poster);
                if (m != null && m.AccessLevel == AccessLevel.Player)
                {
                    PublicOverheadMessage(MessageType.Regular, 0x36, true, Utility.RandomBool() == true ? "A good citizen proclaims!" : "On behalf of a good citizen!");
                }
                else
                {
                    PublicOverheadMessage(MessageType.Regular, 0x3B2, 502976);                   // Hear ye! Hear ye!
                }
            }
        }