示例#1
0
        public override void OnTalk(PlayerMobile pm)
        {
            if (!HasQuest(pm))
            {
                BaseBoat boat = FishQuestHelper.GetBoat(pm);

                if (boat != null && boat is BaseGalleon)
                {
                    if (((BaseGalleon)boat).Scuttled)
                    {
                        pm.SendLocalizedMessage(1116752); //Your ship is a mess!  Fix it first and then we can talk about catching pirates.
                    }
                    else
                    {
                        ProfessionalBountyQuest q = new ProfessionalBountyQuest((BaseGalleon)boat);
                        q.Owner   = pm;
                        q.Quester = this;

                        pm.CloseGump(typeof(MondainQuestGump));
                        pm.SendGump(new MondainQuestGump(q));
                    }
                }
                else
                {
                    SayTo(pm, 1116751); //The ship you are captaining could not take on a pirate ship.  Bring a warship if you want this quest.
                    OnOfferFailed();
                }
            }
        }
示例#2
0
        public override void OnTalk(PlayerMobile pm)
        {
            if (!HasQuest(pm))
            {
                BaseBoat boat = FishQuestHelper.GetBoat(pm);

                if (boat != null && boat is BaseGalleon)
                {
                    if (((BaseGalleon)boat).Scuttled)
                    {
                        pm.SendLocalizedMessage(1116752); //Your ship is a mess!  Fix it first and then we can talk about catching pirates.
                    }
                    else
                    {
                        ProfessionalBountyQuest q = new ProfessionalBountyQuest((BaseGalleon)boat);
                        q.Owner   = pm;
                        q.Quester = this;

                        pm.CloseGump(typeof(MondainQuestGump));
                        pm.SendGump(new MondainQuestGump(q));
                    }
                }
                else if (boat != null && !(boat is BaseGalleon))
                {
                    SayTo(pm, 1116751); //The ship you are captaining could not take on a pirate ship.  Bring a warship if you want this quest.
                }
                else if (m_NextSay < DateTime.UtcNow)
                {
                    if (m_LastSay == 0)
                    {
                        if (this.Map != Map.Tokuno)
                        {
                            Say(1152651);  //I'm G.B. Bigglesby, proprietor of the G.B. Bigglesby Free Trade Floating Emporium.
                        }
                        else
                        {
                            Say("I am {0}, proprietor of {0} Free Trade Coroporation of Tokuno.", Name);
                        }
                        m_LastSay = 1;
                    }
                    else
                    {
                        Say(1152652);  //This sea market be me life's work and 'tis me pride and joy..
                        m_LastSay = 0;
                    }

                    m_NextSay = DateTime.UtcNow + TimeSpan.FromSeconds(5);
                }
            }
        }
示例#3
0
        public override void OnTalk(PlayerMobile player)
        {
            int      distance = 100;
            BaseBoat boat     = FishQuestHelper.GetBoat(player);

            if (boat == null)
            {
                SayTo(player, 1116514); //Bring yer ship around, I might have some work for ye!);
            }
            else
            {
                bool inRange = InRange(boat.Location, distance) && boat.Map == Map;

                if (!FishQuestHelper.HasFishQuest(player, this, inRange))
                {
                    FishMonger monger = FishQuestHelper.GetRandomMonger(player, this);

                    if (monger == null)
                    {
                        SayTo(player, "It seems my fellow fish mongers are on vacation.  Try again later, or perhaps another Facet.");
                    }
                    else
                    {
                        ProfessionalFisherQuest quest = new ProfessionalFisherQuest(player, monger, this, boat);

                        if (quest != null)
                        {
                            quest.Quester = this;
                            quest.Owner   = player;
                            player.CloseGump(typeof(MondainQuestGump));
                            player.SendGump(new MondainQuestGump(quest));

                            if (boat.IsClassicBoat)
                            {
                                SayTo(player, "Such a weak vessle can only catch a weak line.");
                            }
                        }
                    }
                }
            }
        }