|
You last visited: Today at 00:25
Advertisement
EntitySpawn (5378+)
Discussion on EntitySpawn (5378+) within the CO2 Private Server forum part of the Conquer Online 2 category.
03/25/2011, 19:40
|
#1
|
elite*gold: 0
Join Date: Mar 2011
Posts: 165
Received Thanks: 17
|
EntitySpawn (5378+)
Thank you .Kinshi, Thank you Impulse.
Thank you Moderator for closing this (in advance)
#request close.
|
|
|
03/25/2011, 20:11
|
#2
|
elite*gold: 0
Join Date: Dec 2010
Posts: 341
Received Thanks: 255
|
The size of the packet and the offset for the player name is wrong.
Code:
Size: 8 + 214 + (C.Name.Length)
Packet[212] = 4;
Packet[213] = (byte)(C.Name.Length);
WriteString(C.Name, 214, Packet);
|
|
|
03/26/2011, 09:42
|
#3
|
elite*gold: 0
Join Date: Mar 2011
Posts: 165
Received Thanks: 17
|
Quote:
Originally Posted by .Kinshi
The size of the packet and the offset for the player name is wrong.
Code:
Size: 8 + 214 + (C.Name.Length)
Packet[212] = 4;
Packet[213] = (byte)(C.Name.Length);
WriteString(C.Name, 214, Packet);
|
Dude it's impossible the size to be 214 + 8 + Charname lenght
Because in EntitySpawn there's clan name one or 2 offsets more than Char Name. So.. Think about it.
|
|
|
03/26/2011, 10:31
|
#4
|
elite*gold: 0
Join Date: Oct 2009
Posts: 768
Received Thanks: 550
|
Code:
SpawnPacket = new byte[8 + 214 + Name.Length];
WriteUInt16((ushort)(214 + Name.Length), 0, SpawnPacket);
WriteUInt16(10014, 2, SpawnPacket);
SpawnPacket[212] = 3;
SpawnPacket[213] = (byte)_Name.Length;
WriteString(_Name, 214, SpawnPacket);
Works just the way it should.
|
|
|
03/26/2011, 10:38
|
#5
|
elite*gold: 0
Join Date: Mar 2011
Posts: 165
Received Thanks: 17
|
Quote:
Originally Posted by -impulse-
Code:
SpawnPacket = new byte[8 + 214 + Name.Length];
WriteUInt16((ushort)(214 + Name.Length), 0, SpawnPacket);
WriteUInt16(10014, 2, SpawnPacket);
SpawnPacket[212] = 3;
SpawnPacket[213] = (byte)_Name.Length;
WriteString(_Name, 214, SpawnPacket);
Works just the way it should.
|
It Does, but your length is incorrect. If you want to spawn clan name, you gotta increase the length. However, Thank you for your help, I Appreciate that.
This can be closed.
|
|
|
03/26/2011, 10:53
|
#6
|
elite*gold: 0
Join Date: Dec 2010
Posts: 341
Received Thanks: 255
|
Then just add the clan name length onto the spawn packet length.
|
|
|
03/26/2011, 11:56
|
#7
|
elite*gold: 0
Join Date: Mar 2011
Posts: 165
Received Thanks: 17
|
Quote:
Originally Posted by .Kinshi
Then just add the clan name length onto the spawn packet length.
|
Jesus Christ. I'm not gonna argue, You'll see yourself when you get to Clans (if you ever do them)
|
|
|
03/26/2011, 19:00
|
#8
|
elite*gold: 20
Join Date: Aug 2005
Posts: 1,734
Received Thanks: 1,000
|
#Closed
|
|
|
Similar Threads
|
[RELEASE] 5298 EntitySpawn Packet Structures
09/13/2010 - CO2 PServer Guides & Releases - 12 Replies
Entity Spawn: (10014)
Spoiler:
Offset| Type | Value
0 | Short | Size
2 | Short | Type
75 | Byte | Level
78 | Short | HairStyle
80 | Short | CharX
82 | Short | CharY
123 | int | QuizPoints
|
All times are GMT +2. The time now is 00:25.
|
|