|
You last visited: Today at 20:19
Advertisement
0x3026/0x30B8 Packet Problem
Discussion on 0x3026/0x30B8 Packet Problem within the SRO Coding Corner forum part of the Silkroad Online category.
08/11/2017, 05:51
|
#1
|
elite*gold: 53
Join Date: Sep 2014
Posts: 308
Received Thanks: 88
|
0x3026/0x30B8 Packet Problem
First problem:i try to use this packet(0x3026) to get
Charname&Message in Stall Chat
this is Full Packet:
Code:
[S -> C][3026]
09 ................
09 00 ................
41 62 64 65 6C 61 7A 69 7A BOT.......
03 00 ................
68 65 79 testchat.............
this C# Corner:
Code:
if (current.Opcode == 0x3026)
{
string Charname = current.ReadAscii();
string Message = current.ReadAscii();
try
{
Globals.MainWindow.listBox1.Items.Add(Charname);
Globals.MainWindow.listBox1.Items.Add(Message);
}
catch
{
}
}
But i faced a problem when i got the Charname/Messsage and try to send any notice or anything related to Agent i Got this error
NOTE:this packet works fine i got the charname/Message but behind that i faced (SilkroadSecurityAPI) Packet Problem
Second problem:when i try to use this packet(0x30B8) to get
Charname of the Stall Creator behind me
Full Packet:
Code:
[S -> C][30B8]
66 53 07 00 fS..............
0D 00 ................
5B 66 64 5D 27 73 20 73 74 61 6C 6C 2E [BOT]'s.stall....
07 0F 00 00 ................
C# Corner:
Code:
if (current.Opcode == 0x30B8)
{
string charname = current.ReadAscii();
llistBox1.Items.Add(charname);
}
but i got in my listbox something like a (dot)
hope can any one help me
|
|
|
08/11/2017, 12:36
|
#2
|
elite*gold: 0
Join Date: Jan 2009
Posts: 314
Received Thanks: 685
|
First and foremost, you should take a look at my documentation regarding those packets.
You can match them (most of the time) line by line with your output from edxAnalyzer. But you need respect any branches (if else) that may occur.
Your 0x3026 code is ignoring the chatType and also the branches.
Visually speaking this is what happens with your code...
...and what it should look like
Your 0x308B code is ignoring the UniqueID. But more importantly, you can only read the stall name that "someone" created from 0x30B8 using ReadAscii().
In order to get the character name using the UniqueID you have to read the spawn packets first. More on that  and  .
|
|
|
08/11/2017, 16:13
|
#3
|
elite*gold: 53
Join Date: Sep 2014
Posts: 308
Received Thanks: 88
|
Quote:
Originally Posted by DaxterSoul
First and foremost, you should take a look at my documentation regarding those packets.
You can match them (most of the time) line by line with your output from edxAnalyzer. But you need respect any branches (if else) that may occur.
Your 0x3026 code is ignoring the chatType and also the branches.
Visually speaking this is what happens with your code...
...and what it should look like
Your 0x308B code is ignoring the UniqueID. But more importantly, you can only read the stall name that "someone" created from 0x30B8 using ReadAscii().
In order to get the character name using the UniqueID you have to read the spawn packets first. More on that  and  .
|
Opcode 0x30B8
i can read the charname if the stall created normally like [Bot]'stall
and remove [,]'stall name from stall so i got the char name wihout problem
but if the stall created like that Bot without [BOT]'stall i got a something like dot so i want to know what the diff between get the charname by remove it from [,]'stall and by get as BOT ?
in case of opcode 0x3026 ur images i cannot see it to understant what you say
and about spawn packet and read Unique id and charname and it's items
it's complex with me i try to handle it but every time fail !
|
|
|
08/13/2017, 13:27
|
#4
|
elite*gold: 85
Join Date: Aug 2010
Posts: 1,278
Received Thanks: 524
|
Quote:
Originally Posted by Mr.Awesome1337
Opcode 0x30B8
i can read the charname if the stall created normally like [Bot]'stall
and remove [,]'stall name from stall so i got the char name wihout problem
but if the stall created like that Bot without [BOT]'stall i got a something like dot so i want to know what the diff between get the charname by remove it from [,]'stall and by get as BOT ?
in case of opcode 0x3026 ur images i cannot see it to understant what you say
and about spawn packet and read Unique id and charname and it's items
it's complex with me i try to handle it but every time fail !
|
so simply you cannot parse single spawn packet , and want to read the char name from opening a stall by the target char , DaxterSoul trying to tell you how to handle the packet itself and the chat type byte
anyways when i back home i will send to you the code that you want ..
|
|
|
08/13/2017, 17:44
|
#5
|
elite*gold: 53
Join Date: Sep 2014
Posts: 308
Received Thanks: 88
|
Quote:
Originally Posted by Eslam Galull
so simply you cannot parse single spawn packet , and want to read the char name from opening a stall by the target char , DaxterSoul trying to tell you how to handle the packet itself and the chat type byte
anyways when i back home i will send to you the code that you want ..
|
Thanks alot..
How i can contact with you?
|
|
|
08/14/2017, 10:31
|
#6
|
elite*gold: 85
Join Date: Aug 2010
Posts: 1,278
Received Thanks: 524
|
Quote:
Originally Posted by Mr.Awesome1337
Thanks alot..
How i can contact with you?
|
im sry i forget you yesterday i was so tired ,
skype : eslam.galull
i will post the code at night today isa
|
|
|
08/14/2017, 17:43
|
#7
|
elite*gold: 53
Join Date: Sep 2014
Posts: 308
Received Thanks: 88
|
Quote:
Originally Posted by Eslam Galull
im sry i forget you yesterday i was so tired ,
skype : eslam.galull
i will post the code at night today isa
|
ok thanks iam waiting
|
|
|
08/15/2017, 20:56
|
#8
|
elite*gold: 85
Join Date: Aug 2010
Posts: 1,278
Received Thanks: 524
|
0x30B
Code:
if (packet.Opcode == 0x30B8) //Get Staller Name
{
Thread t = new Thread(() => Stall_Func.Stall_Parse(packet));
t.Start();
}
public static void Stall_Parse(Packet packet)
{
try
{
packet.ReadUInt32();
string StallName = packet.ReadAscii();
if (StallName.Contains("]'s stall."))
{
String Name = getBetween(StallName, "[", "]'s stall.");
}
else
{
("Please Open a Stall with Normal Stall Name Like : [YourName]'s stall. ");
}
}
catch
{
("EX => Parsing Stall P ");
}
}
0x3026
Code:
else if (_pck.Opcode == 0x3026) // Server Chat
{
Thread t = new Thread(() => PmFunction.Parse_Pm(_pck));
t.Start();
}
public static void Parse_Pm(Packet packet)
{
string MessageQ = string.Empty;
string SenderQ = string.Empty;
try
{
byte Type = packet.ReadUInt8();
else if (Type != 7)
{
SenderQ = packet.ReadAscii();
MessageQ = packet.ReadAscii();
switch (Type)
{
case 9: // Stall Chat
txtStallChat.Text += "[" + DateTime.Now.ToString("h:mm:ss tt") + "] " + SenderQ + " : " + MessageQ + Environment.NewLine;
break;
}
}
}
catch
{
Console.WriteLine("Pm Parse Error");
}
}
P.S we just try to help you as somebody else helped us before, next time no one would gives you a ready to use Code
G.L
|
|
|
08/17/2017, 00:20
|
#9
|
elite*gold: 0
Join Date: Feb 2009
Posts: 46
Received Thanks: 5
|
Eslam , can i ask why u create new thread for every if & elseif (_pck.Opcode == 0xZZZZ) case ?
|
|
|
08/17/2017, 17:47
|
#10
|
elite*gold: 0
Join Date: Jan 2009
Posts: 152
Received Thanks: 28
|
iam trying to get character name in general chat but always i get its id, how can i get the character name ?
case 1:
uint num2 = current.ReadUInt32();
string str5 = current.ReadAscii();
String timeStampx = GetTimestamp(DateTime.Now);
Globals.MainWindow.richTextBox2.AppendText("[" + timeStampx + "](General) " + num2 + " : " + str5 + "\r\n");
break;
|
|
|
08/17/2017, 18:46
|
#11
|
elite*gold: 85
Join Date: Aug 2010
Posts: 1,278
Received Thanks: 524
|
It was an old src , now i just run it in a packet handler moud.
You cant get char name in all chat untill u parse single spawn packet
|
|
|
08/17/2017, 20:44
|
#12
|
elite*gold: 0
Join Date: Jan 2009
Posts: 152
Received Thanks: 28
|
Quote:
Originally Posted by Eslam Galull
It was an old src , now i just run it in a packet handler moud.
You cant get char name in all chat untill u parse single spawn packet
|
can you please show me how to parse it ? and put character name in all chat case ?
Thanks in advance
|
|
|
08/18/2017, 16:45
|
#13
|
elite*gold: 85
Join Date: Aug 2010
Posts: 1,278
Received Thanks: 524
|
You want me give you a ready to use codes , so u can makes your auto events for your coming server ?
|
|
|
08/18/2017, 23:55
|
#14
|
elite*gold: 0
Join Date: Jan 2009
Posts: 152
Received Thanks: 28
|
Quote:
Originally Posted by Eslam Galull
You want me give you a ready to use codes , so u can makes your auto events for your coming server ?
|
iam not requesting a ready to use codes... i requested a guide ... anyway thanks.
|
|
|
08/19/2017, 01:50
|
#15
|
elite*gold: 350
Join Date: Aug 2015
Posts: 1,999
Received Thanks: 1,188
|
Quote:
Originally Posted by memoxl
iam not requesting a ready to use codes... i requested a guide ... anyway thanks.
|
parse 3015, 3017, 3019 (single & group spawn packets)
save nearby players in a dictionary (or a custom list) and delete players by UniqueID upon receiving 0x3016 (gameobj despawn)
Code:
if(_nearbyPlayers.ContainsKey(uniqueidfromchatpacket))
string charname = _nearbyPlayers[uniqueidfromchatpacket];
TIP: you don't need to parse the whole thing. google BinaryReader.Position
|
|
|
 |
|
Similar Threads
|
[Help] Weather Packet (My First Packet)
06/07/2014 - CO2 Private Server - 95 Replies
delete this thread.
|
Understanding the Packet System - Basics of a Packet explained
11/03/2012 - Cabal Online - 30 Replies
Read the advice first...
*****************UPDATED 12/11/2011*********************************
**** ADDED VB6 PROXY BOT SOURCE-CODE, WORKING EXAMPLE OF PROXY BOT******
************************************************* *****************
The following CONSTANTS have been flagged, this means they appear in EVERY Packet exchange from client to server and server to client
Red = Packet Id - Each packet has a unique ID number, in this case AA02, Each Packet id Relates to a specific...
|
[Request] Packet Structure for CharData Packet
05/16/2011 - Silkroad Online - 4 Replies
can someone tell me which structure the CharData packet has? i would really appreciate this, since im still noob in such things. its just too high for me/ too much information for my head. :handsdown:
S->C(3013)...
|
[Question] Packet data , packet editing ??
10/13/2009 - 9Dragons - 2 Replies
I would like to know :
What is packet data?
How do i get the address for hacking a item in game?
How to use it ??
|
All times are GMT +1. The time now is 20:19.
|
|