mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-08 21:44:35 +02:00
Implement the actor initial position packet and set state packet.
This commit is contained in:
parent
af2262c4b1
commit
327dfc656b
5 changed files with 40 additions and 10 deletions
|
@ -13,7 +13,16 @@ namespace FFXIVClassic_Map_Server.packets.send.actor
|
|||
public const ushort OPCODE = 0x00CE;
|
||||
public const uint PACKET_SIZE = 0x48;
|
||||
|
||||
public static SubPacket buildPacket(uint playerActorID, uint actorID)
|
||||
public const uint SPAWNTYPE_NORMAL = 1;
|
||||
public const uint SPAWNTYPE_WARP1 = 2;
|
||||
public const uint SPAWNTYPE_WARP2 = 3;
|
||||
|
||||
public const float INNPOS_X = 157.550003f;
|
||||
public const float INNPOS_Y = 000.000000f;
|
||||
public const float INNPOS_Z = 165.050003f;
|
||||
public const float INNPOS_ROT = -1.530000f;
|
||||
|
||||
public static SubPacket buildPacket(uint playerActorID, uint actorID, float x, float y, float z, float rotation)
|
||||
{
|
||||
byte[] data = new byte[PACKET_SIZE-0x20];
|
||||
|
||||
|
@ -21,13 +30,16 @@ namespace FFXIVClassic_Map_Server.packets.send.actor
|
|||
{
|
||||
using (BinaryWriter binWriter = new BinaryWriter(mem))
|
||||
{
|
||||
|
||||
binWriter.Write((Int32)0);
|
||||
binWriter.Write((Int32)0);
|
||||
binWriter.Write((Single)x);
|
||||
binWriter.Write((Single)y);
|
||||
binWriter.Write((Single)z);
|
||||
binWriter.Write((Single)rotation);
|
||||
}
|
||||
data = mem.GetBuffer();
|
||||
}
|
||||
|
||||
SubPacket packet = new SubPacket(OPCODE, playerActorID, actorID, data);
|
||||
return packet;
|
||||
return new SubPacket(OPCODE, playerActorID, actorID, data);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue