Entity Spawn packet 5017

12/21/2011 17:24 Kiyono#1
So I checked different sources and it seems that not one public source unless I missed it has the complete Entity Spawn packet for 5017.
Taking bits and pieces from sources I got the following offsets and really random different packet sizes.

Code:
UID = 4
overlaymesh = 8 //all 8? wtf?
Mesh = 8
Avatar = 8
Model = 8
Status = 12
GuildID = 20
GuildPosition = 23
Garment = 24
Helmet = 28
Armor = 32
RHand = 36
LHand = 40
HP = 48
MobLevel = 50
X = 52
Y = 54
Hair = 56
Direction = 58
Action = 59
Reborn = 60
Level = 62
Namesomething? = 80 //value 255
NameLength = 81
Name = 82
So does anyone know what I'm missing or if this is even correct up till now?
12/21/2011 18:19 _DreadNought_#2
Those are very easy to figure out since theres visual changes when they are correct. Trial and error.
12/21/2011 18:23 nTL3fTy#3
Here's what I have, from an old project of mine:
offsetdatatypedescription
0ushort[2]header
4uintid
8uintlookface
12ulongeffect
20uintguild id/rank
24uintgarment itemtype
28uinthelmet itemtype
32uintarmor itemtype
36uintright weapon itemtype
40uintleft weapon itemtype
44uintunknown
48ushortmonster life
50ushortmonster level
52ushortposition x
54ushortposition y
56ushorthair
58bytedirection
59byteaction
60byterebirth
61byteunknown
62ushortlevel
64byteunknown
65bytenobility ranktype
.........
80stringliststrings
12/21/2011 22:26 Kiyono#4
Thanks, for the answers, though, it's weird that TQ just randomly skipped some values for no real reason.
12/22/2011 06:48 pro4never#5
Quote:
Originally Posted by nTL3fTy View Post
Here's what I have, from an old project of mine:
offsetdatatypedescription
0ushort[2]header
4uintid
8uintlookface
12ulongeffect
20uintguild id/rank
24uintgarment itemtype
28uinthelmet itemtype
32uintarmor itemtype
36uintright weapon itemtype
40uintleft weapon itemtype
44uintunknown
48ushortmonster life
50ushortmonster level
52ushortposition x
54ushortposition y
56ushorthair
58bytedirection
59byteaction
60byterebirth
61byteunknown
62ushortlevel
64byteunknown
65bytenobility ranktype
.........
80stringliststrings
That source makes me cry every time I look at it.

I remember trying to look through it to see how you handled something (I thin it was to do with magic attack types) and it took me probably 20 minutes to track through all the necessary methods lol.

Everything is labeled in tq'isms.

</offtopic>

@Kiyono: Yahhh there's lots of packets with un-used offsets. I can't think of a good example right now but I do remember a few people mentioning there are a few where the client doesn't even process the offset so it's not like we just haven't logged what it does for subtypes or w/e.
12/22/2011 14:12 BaussHacker#6
Quote:
Originally Posted by pro4never View Post
That source makes me cry every time I look at it.

I remember trying to look through it to see how you handled something (I thin it was to do with magic attack types) and it took me probably 20 minutes to track through all the necessary methods lol.
That's how I have it with your sources, but we all do things different.
12/22/2011 14:58 Kiyono#7
Quote:
Originally Posted by pro4never View Post
@Kiyono: Yahhh there's lots of packets with un-used offsets. I can't think of a good example right now but I do remember a few people mentioning there are a few where the client doesn't even process the offset so it's not like we just haven't logged what it does for subtypes or w/e.
I wasn't implying that you guys were too lazy to log them, just saying that TQ is weird for having gaps in their packets.
12/22/2011 17:24 CptSky#8
Mine look a little bit different. But, it is based on what I saw with packet sniffing. For the two values used by the monster, it is useless to set them for a player, but you can.

Code:
private struct MsgInfo      
{
     public MsgHeader Header;
     public Int32 UniqId;
     public Int32 Look;
     public Int64 Flags;
     public Int16 SynUID;
     public Byte Unknow1;
     public Byte SynRank;
     public Int32 GarmentId;
     public Int32 HeadId;
     public Int32 ArmorId;
     public Int32 RightHandId;
     public Int32 LeftHandId;
     public Int32 Unknow2;
     public UInt16 CurHP; //Used for Monster, but can be used for Player
     public Int16 Level; //Used for Monster, but can be used for Player
     public UInt16 X;
     public UInt16 Y;
     public Int16 Hair;
     public Byte Direction;
     public Byte Action;
     public Byte Metempsychosis;
     public Int16 Level;
     public Int32 Unknow3;
     public Int32 NobilityRank;
     public Int32 UniqId;
     public Int32 NobilityPosition;
     public Byte StringCount;
     public TQString[] Strings;
};