2016-06-08 22:29:04 +01:00
|
|
|
|
using System;
|
2015-12-04 02:00:05 -05:00
|
|
|
|
using System.IO;
|
|
|
|
|
|
2016-08-22 10:43:04 -04:00
|
|
|
|
using FFXIVClassic.Common;
|
|
|
|
|
|
|
|
|
|
namespace FFXIVClassic_Map_Server.packets.send.actor
|
2015-12-04 02:00:05 -05:00
|
|
|
|
{
|
2015-12-29 01:20:46 -05:00
|
|
|
|
class SetActorIconPacket
|
2015-12-04 02:00:05 -05:00
|
|
|
|
{
|
2015-12-29 01:20:46 -05:00
|
|
|
|
public const uint DISCONNECTING = 0x00010000;
|
|
|
|
|
public const uint ISGM = 0x00020000;
|
|
|
|
|
public const uint ISAFK = 0x00000100;
|
2015-12-04 02:00:05 -05:00
|
|
|
|
|
2015-12-29 01:20:46 -05:00
|
|
|
|
public const ushort OPCODE = 0x0145;
|
|
|
|
|
public const uint PACKET_SIZE = 0x28;
|
|
|
|
|
|
2016-06-15 00:08:05 +01:00
|
|
|
|
public static SubPacket BuildPacket(uint playerActorID, uint targetActorID, uint iconCode)
|
2015-12-04 02:00:05 -05:00
|
|
|
|
{
|
|
|
|
|
byte[] data = new byte[PACKET_SIZE - 0x20];
|
2015-12-29 01:20:46 -05:00
|
|
|
|
|
2015-12-04 02:00:05 -05:00
|
|
|
|
using (MemoryStream mem = new MemoryStream(data))
|
|
|
|
|
{
|
|
|
|
|
using (BinaryWriter binWriter = new BinaryWriter(mem))
|
|
|
|
|
{
|
2015-12-29 01:20:46 -05:00
|
|
|
|
binWriter.Write((UInt32)iconCode);
|
2015-12-04 02:00:05 -05:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2016-06-15 00:08:05 +01:00
|
|
|
|
return new SubPacket(OPCODE, playerActorID, targetActorID, data);
|
2015-12-04 02:00:05 -05:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|