コード例 #1
0
ファイル: MapClient.cs プロジェクト: x3sphiorx/SagaRO2
        /// <summary>
        /// Send the Quest information of a client
        /// </summary>
        public void SendQuestInfo()
        {
            List <SagaDB.Quest.Quest> quests = new List <SagaDB.Quest.Quest>();

            SagaDB.Quest.Quest q = Quest.QuestsManager.GetActiveQuest(this.Char);

            if (q != null)
            {
                quests.Add(q);
            }
            q = Quest.QuestsManager.GetActivePersonalQuest(this.Char);
            if (q != null)
            {
                quests.Add(q);
            }
            Packets.Server.QuestInfo p1 = new SagaMap.Packets.Server.QuestInfo();
            p1.SetQuestInfo(quests);
            this.netIO.SendPacket(p1, this.SessionID);;
        }
コード例 #2
0
ファイル: AtCommand.cs プロジェクト: Willyham/SagaRO2
        private void ProcessTest(MapClient client, string args)
        {
            string[] arg = args.Split(' ');

            Packets.Server.QuestInfo p = new SagaMap.Packets.Server.QuestInfo();
            SagaDB.Quest.Quest quest = new SagaDB.Quest.Quest();
            quest.ID = uint.Parse(arg[0]);
            Dictionary<uint, SagaDB.Quest.Step> steps = new Dictionary<uint, SagaDB.Quest.Step>();
            for (int i = 1; i < arg.Length; i++)
            {
                SagaDB.Quest.Step step = new SagaDB.Quest.Step();
                step.ID = uint.Parse(arg[i]);
                step.step = (byte)i;
                step.Status = 1;
                steps.Add(uint.Parse(arg[i]), step);
            }
            quest.Steps = steps;
            List<SagaDB.Quest.Quest> lists = new List<SagaDB.Quest.Quest>();
            lists.Add(quest);
            p.SetQuestInfo(lists);
            client.netIO.SendPacket(p, client.SessionID);
        }
コード例 #3
0
ファイル: MapClient.cs プロジェクト: Willyham/SagaRO2
        /// <summary>
        /// Send the Quest information of a client
        /// </summary>
        public void SendQuestInfo()
        {
            List<SagaDB.Quest.Quest> quests = new List<SagaDB.Quest.Quest>();
            SagaDB.Quest.Quest q = Quest.QuestsManager.GetActiveQuest(this.Char);

            if (q != null)
            {
                quests.Add(q);
            }
            q = Quest.QuestsManager.GetActivePersonalQuest(this.Char);
            if (q != null)
            {
                quests.Add(q);
            }
            Packets.Server.QuestInfo p1 = new SagaMap.Packets.Server.QuestInfo();
            p1.SetQuestInfo(quests);
            this.netIO.SendPacket(p1, this.SessionID); ;
        }