ServUO (Pub 57) Escortables announcing "destination" when approached.

librettomafia

Citizen
Feb 27, 2018
23
2
3
24
Shard Name
Age of Renaissance
Hello,
I was wondering what needs to be changed in order to have Escorts announce a message when approached along with still having the "destination" command.

Thanks in advance.
 

RedBeard

Squire
May 19, 2013
398
72
28
48
Palm Beach Gardens, Florida USA
Shard Name
Virtus Imperium
Look at these portions of code for example:

From BaseQuest.cs Line 207
Code:
  if (m_Quester is BaseEscort)
            {
                BaseEscort escort = (BaseEscort)m_Quester;

                if (escort.SetControlMaster(m_Owner))
                {
                    escort.Quest = this;
                    escort.LastSeenEscorter = DateTime.UtcNow;
                    escort.StartFollow();
                    escort.AddHash(Owner);

                    string region = escort.GetDestination();

                    if (!string.IsNullOrEmpty(region))
                        escort.Say(1042806, region); // Lead on! Payment will be made when we arrive at ~1_DESTINATION~!
                    else
                        escort.Say(1042806, "destination"); // Lead on! Payment will be made when we arrive at ~1_DESTINATION~!

                    m_Owner.LastEscortTime = DateTime.UtcNow;
                }
            }

            // tick tack    
            StartTimer();
        }
From BaseQuester.cs Line 92
Code:
 public override void AddCustomContextEntries(Mobile from, List<ContextMenuEntry> list)
        {
            base.AddCustomContextEntries(from, list);

            if (from.Alive && from is PlayerMobile && TalkNumber > 0 && CanTalkTo((PlayerMobile)from))
                list.Add(new TalkEntry(this));
        }

        public override void OnMovement(Mobile m, Point3D oldLocation)
        {
            if (m.Alive && m is PlayerMobile)
            {
                PlayerMobile pm = (PlayerMobile)m;

                int range = GetAutoTalkRange(pm);

                if (m.Alive && range >= 0 && InRange(m, range) && !InRange(oldLocation, range) && CanTalkTo(pm))
                    OnTalk(pm, false);
            }
        }
tenor (1).gif