mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-11 06:54:43 +02:00
Fixed bug with dialog treating all characters as men.
This commit is contained in:
parent
958a87edf2
commit
c38caffaf1
3 changed files with 31 additions and 1 deletions
|
@ -32,7 +32,7 @@ namespace Meteor.Map.packets.send.actor
|
|||
public const ushort OPCODE = 0x013D;
|
||||
public const uint PACKET_SIZE = 0x48;
|
||||
|
||||
public static SubPacket BuildPacket(uint sourceActorId, uint displayNameID, string customName)
|
||||
public static SubPacket BuildPacket(uint sourceActorId, uint displayNameID, string customName, bool isSexMale = true)
|
||||
{
|
||||
byte[] data = new byte[PACKET_SIZE - 0x20];
|
||||
|
||||
|
@ -45,6 +45,9 @@ namespace Meteor.Map.packets.send.actor
|
|||
if (customName != null && (displayNameID == 0 || displayNameID == 0xFFFFFFFF))
|
||||
{
|
||||
binWriter.Write(Encoding.ASCII.GetBytes(customName), 0, Encoding.ASCII.GetByteCount(customName) >= 0x20 ? 0x19 : Encoding.ASCII.GetByteCount(customName));
|
||||
|
||||
binWriter.BaseStream.Seek(0x24, SeekOrigin.Begin);
|
||||
binWriter.Write((UInt32)(isSexMale ? 0 : 1));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue