Esempio n. 1
0
            public override void OnClick()
            {
                if (!(m_Mobile is PlayerMobile))
                {
                    return;
                }

                string myQuest = CharacterDatabase.GetQuestInfo(m_Mobile, "FishingQuest");

                int    nAllowedForAnotherQuest = FishingQuestFunctions.QuestTimeNew(m_Mobile);
                int    nServerQuestTimeAllowed = DifficultyLevel.GetTimeBetweenQuests();
                int    nWhenForAnotherQuest    = nServerQuestTimeAllowed - nAllowedForAnotherQuest;
                string sAllowedForAnotherQuest = nWhenForAnotherQuest.ToString();

                if (CharacterDatabase.GetQuestState(m_Mobile, "FishingQuest"))
                {
                    m_Mobile.PrivateOverheadMessage(MessageType.Regular, 1150, false, "You are already on a quest. Return here when you are done.", m_Mobile.NetState);
                }
                else if (nWhenForAnotherQuest > 0)
                {
                    m_Mobile.PrivateOverheadMessage(MessageType.Regular, 1150, false, "There are no quests at the moment. Check back in " + sAllowedForAnotherQuest + " minutes.", m_Mobile.NetState);
                }
                else
                {
                    int nFame = m_Mobile.Fame * 2;
                    nFame = Utility.RandomMinMax(0, nFame) + 2000;

                    FishingQuestFunctions.FindTarget(m_Mobile, nFame);

                    string TellQuest = FishingQuestFunctions.QuestStatus(m_Mobile) + ".";
                    m_Mobile.PrivateOverheadMessage(MessageType.Regular, 1150, false, TellQuest, m_Mobile.NetState);
                }
            }
Esempio n. 2
0
            public override void OnClick()
            {
                if (!(m_Mobile is PlayerMobile))
                {
                    return;
                }

                PlayerMobile mobile = (PlayerMobile)m_Mobile;

                string myQuest = CharacterDatabase.GetQuestInfo(m_Mobile, "AssassinQuest");

                int    nAllowedForAnotherQuest = AssassinFunctions.QuestTimeNew(m_Mobile);
                int    nServerQuestTimeAllowed = DifficultyLevel.GetTimeBetweenQuests();
                int    nWhenForAnotherQuest    = nServerQuestTimeAllowed - nAllowedForAnotherQuest;
                string sAllowedForAnotherQuest = nWhenForAnotherQuest.ToString();

                if (CharacterDatabase.GetQuestState(m_Mobile, "AssassinQuest"))
                {
                    m_Giver.Say("You already have your orders. Return to me when you are done with the task.");
                }
                else if (mobile.NpcGuild != NpcGuild.AssassinsGuild)                   // HE WILL ONLY TALK GUILD MEMBERS
                {
                    m_Giver.Say("Hmmm...you do not seem the type I wish to discuss matters with.");
                }
                else if (m_Mobile.Karma > -1250)                   // HE WILL ONLY TALK TO THE UNSAVORY GUILD MEMBERS
                {
                    m_Giver.Say("Hmmm...maybe show me that you could handle such tasks first.");
                }
                else if (nWhenForAnotherQuest > 0)
                {
                    m_Giver.Say("I have nothing for you at the moment. Check back in " + sAllowedForAnotherQuest + " minutes.");
                }
                else
                {
                    int nFame = m_Mobile.Fame * 2;
                    nFame = Utility.RandomMinMax(0, nFame) + 2000;

                    if (Utility.RandomMinMax(1, 100) > 30)
                    {
                        AssassinFunctions.FindTarget(m_Mobile, nFame);
                    }
                    else
                    {
                        AssassinFunctions.FindInnocentTarget(m_Mobile);
                    }

                    string TellQuest = AssassinFunctions.QuestStatus(m_Mobile) + ".";
                    m_Giver.Say(TellQuest);
                }
            }
Esempio n. 3
0
        public static string ThiefAllowed(Mobile from)
        {
            int    nAllowedForAnotherQuest = ThiefTimeNew(from);
            int    nServerQuestTimeAllowed = DifficultyLevel.GetTimeBetweenQuests();
            int    nWhenForAnotherQuest    = nServerQuestTimeAllowed - nAllowedForAnotherQuest;
            string sAllowedForAnotherQuest = nWhenForAnotherQuest.ToString();

            if (nWhenForAnotherQuest > 0)
            {
                return(sAllowedForAnotherQuest);
            }

            return(null);
        }