Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > Silkroad Online > SRO Coding Corner
You last visited: Today at 18:38

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Parsing Quests in 0x3013 (vSRO 188)

Discussion on Parsing Quests in 0x3013 (vSRO 188) within the SRO Coding Corner forum part of the Silkroad Online category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Feb 2008
Posts: 961
Received Thanks: 648
Parsing Quests in 0x3013 (vSRO 188)

Hello,

I'm stuck somewhere in 0x3013 parsing (self-spawn packet). I reached the quests part and I couldn't parse it correctly. There is a "completed quests" part which is just a WORD and a for loop with DWORD for each one, but what comes next is the "Active/Accepted quests". Does anyone have any clue about that part?
Part of my code :
Code:
                            ushort CompletedQuestCount = PacketItem.ReadUInt16();
                            for (int q = 0; q < CompletedQuestCount;q++ )
                            {
                                PacketItem.ReadUInt32(); //refquestID
                            }
                            byte activeQuest = PacketItem.ReadUInt8();
                            for (int q = 0; q < activeQuest; q++)
                            {
                                PacketItem.ReadUInt32(); //refquestID
                                PacketItem.ReadUInt16();
                                byte questtype = PacketItem.ReadUInt8();
                                byte objectiveCount = PacketItem.ReadUInt8();
                                for (int obj = 0; obj < objectiveCount; obj++)
                                {
                                    PacketItem.ReadUInt8Array(11);
                                    string objj =PacketItem.ReadAscii();
                                    byte objtask = PacketItem.ReadUInt8();
                                    for (int ot = 0; ot < objtask; ot++)
                                    {
                                        PacketItem.ReadUInt32();
                                    }
                                }
Thanks

EDIT : I fixed it on my own. The problem was because there should have been a condition like this :
Code:
if (questtype==8)
{
PacketItem.ReadUInt8();
continue;
}
magicanoo is offline  
Old 06/29/2015, 08:57   #2
 
elite*gold: 0
Join Date: May 2013
Posts: 38
Received Thanks: 10
Hi. Im not totaly sure this is full structure...
Theres a few thing you can do to skip teh quest part(if you don't need it)
1. Use charUID parsed from x3020 packet. Just search through bytes for a match. Actually i suggest not to use this one as it may interfere with quests ids. Its pretty rare though
2. Save teh char name when its being selected and search for it.
amra85 is offline  
Thanks
1 User
Old 06/29/2015, 17:03   #3
 
elite*gold: 0
Join Date: Feb 2008
Posts: 961
Received Thanks: 648
Quote:
Originally Posted by amra85 View Post
Hi. Im not totaly sure this is full structure...
Theres a few thing you can do to skip teh quest part(if you don't need it)
1. Use charUID parsed from x3020 packet. Just search through bytes for a match. Actually i suggest not to use this one as it may interfere with quests ids. Its pretty rare though
2. Save teh char name when its being selected and search for it.
I am trying to dynamically parse everything that might be useful in in the self-spawn packet. I reached the point where almost all types of quests are parsed correctly as the image following :



I'm still looking for different types of quests to take and try to parse, because I discovered that each quest type has its own custom bytes.
magicanoo is offline  
Old 06/29/2015, 17:21   #4
dotCom
 
Devsome's Avatar
 
elite*gold: 12400
The Black Market: 104/0/0
Join Date: Mar 2009
Posts: 15,880
Received Thanks: 4,386
Quote:
Originally Posted by magicanoo View Post
I am trying to dynamically parse everything that might be useful in in the self-spawn packet. I reached the point where almost all types of quests are parsed correctly as the image following :



I'm still looking for different types of quests to take and try to parse, because I discovered that each quest type has its own custom bytes.
I guess the bytes for each quest are in the Media.pk2
So you can parse it and save it into a dictionary
Devsome is offline  
Reply


Similar Threads Similar Threads
[HELP] Packet parsing
12/31/2014 - SRO Coding Corner - 6 Replies
need to get red thing thanks.
[QUESTION]Missing quests from VSRO 1.88
12/02/2013 - SRO Private Server - 0 Replies
anyone know why CH_TUTORIAL and EU_TUTORIAL are missing from the Sro client *********************** I Checked the database they are enabled in all tables I Checked the client text files they are enabled i check the server files scripts folder and they are missing but so are many quests that are present in the game. My understanding is that Sro devs hard coded some quests into the client and then got lazy or didn't want to update the client every time they added a quest so they used...
Parsing
02/24/2013 - SRO Coding Corner - 2 Replies
Hey, can anyone please parse that packet(3013), its for my bot, but I got problem when I'm trying to parse charname and X,Y cords, others I know probably. Thanks... Here it is: 4d e8 62 2b 79 07 00 00 44 37 37 4d db be 00 00 M.b+y...D77M.... 00 00 00 57 01 00 00 a4 cd 92 00 00 00 00 00 aa ...W............ 05 00 00 00 00 05 00 00 00 00 8f 09 00 00 d1 17 ................ 00 00 00 00 00 00 00 00 00 00 00 00 37 2d 00 00 ............7-.. 00 00 00 03 75 00 00 00 00 00 00...
[VSRO] HOW TO EDIT QUESTS ?
04/01/2012 - SRO Private Server - 1 Replies
how to edit quest for an example .. i want to remove the inventory expansion quest .. how to do this ? and how to edit quests or add a new quests ? if anyone knows please share :D
Vsro changing Exp&SP rates of quests?
09/26/2011 - SRO Private Server - 2 Replies
Are there settings i can change the rates of them?



All times are GMT +2. The time now is 18:38.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.