mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-04-26 06:37:45 +00:00
Added packets for various search things Showmo found.
This commit is contained in:
parent
e819603432
commit
af121f52bd
13 changed files with 104 additions and 14 deletions
|
@ -264,6 +264,7 @@
|
||||||
<Compile Include="packets\send\recruitment\EndRecruitmentPacket.cs" />
|
<Compile Include="packets\send\recruitment\EndRecruitmentPacket.cs" />
|
||||||
<Compile Include="packets\send\recruitment\RecruiterStatePacket.cs" />
|
<Compile Include="packets\send\recruitment\RecruiterStatePacket.cs" />
|
||||||
<Compile Include="packets\send\recruitment\StartRecruitingResponse.cs" />
|
<Compile Include="packets\send\recruitment\StartRecruitingResponse.cs" />
|
||||||
|
<Compile Include="packets\send\search\ItemSearchClosePacket.cs" />
|
||||||
<Compile Include="packets\send\search\PlayerSearchResult.cs" />
|
<Compile Include="packets\send\search\PlayerSearchResult.cs" />
|
||||||
<Compile Include="packets\send\search\ItemSearchResult.cs" />
|
<Compile Include="packets\send\search\ItemSearchResult.cs" />
|
||||||
<Compile Include="packets\send\search\PlayerSearchCommentResultPacket.cs" />
|
<Compile Include="packets\send\search\PlayerSearchCommentResultPacket.cs" />
|
||||||
|
@ -271,6 +272,12 @@
|
||||||
<Compile Include="packets\send\search\ItemSearchResultsEndPacket.cs" />
|
<Compile Include="packets\send\search\ItemSearchResultsEndPacket.cs" />
|
||||||
<Compile Include="packets\send\search\ItemSearchResultsBodyPacket.cs" />
|
<Compile Include="packets\send\search\ItemSearchResultsBodyPacket.cs" />
|
||||||
<Compile Include="packets\send\search\ItemSearchResultsBeginPacket.cs" />
|
<Compile Include="packets\send\search\ItemSearchResultsBeginPacket.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerResultBodyPacket.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerResultEndPacket.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerResultUpdatePacket.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerSearchHistoryPacket.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerSearchHistoryResult.cs" />
|
||||||
|
<Compile Include="packets\send\search\RetainerSearchResult.cs" />
|
||||||
<Compile Include="packets\send\SendMessagePacket.cs" />
|
<Compile Include="packets\send\SendMessagePacket.cs" />
|
||||||
<Compile Include="packets\send\SetMapPacket.cs" />
|
<Compile Include="packets\send\SetMapPacket.cs" />
|
||||||
<Compile Include="packets\send\SetMusicPacket.cs" />
|
<Compile Include="packets\send\SetMusicPacket.cs" />
|
||||||
|
|
|
@ -3,7 +3,7 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class ItemSearchClosePacket
|
class ItemSearchClosePacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,7 +3,7 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class ItemSearchResultsBeginPacket
|
class ItemSearchResultsBeginPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,10 +2,9 @@
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System;
|
using System;
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
using FFXIVClassic_Map_Server.packets.send.search;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class ItemSearchResultsBodyPacket
|
class ItemSearchResultsBodyPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,7 +3,7 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class ItemSearchResultsEndPacket
|
class ItemSearchResultsEndPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,9 +3,8 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
using System;
|
using System;
|
||||||
using FFXIVClassic_Map_Server.packets.send.search;
|
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class PlayerSearchCommentResultPacket
|
class PlayerSearchCommentResultPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,9 +3,8 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
using System;
|
using System;
|
||||||
using FFXIVClassic_Map_Server.packets.send.search;
|
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class PlayerSearchInfoResultPacket
|
class PlayerSearchInfoResultPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,7 +3,7 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class RetainerResultBodyPacket
|
class RetainerResultBodyPacket
|
||||||
{
|
{
|
||||||
|
@ -13,6 +13,14 @@ namespace FFXIVClassic_Map_Server.packets.send.social
|
||||||
public static SubPacket BuildPacket(uint sourceActorId, bool isSuccess, string nameToAdd)
|
public static SubPacket BuildPacket(uint sourceActorId, bool isSuccess, string nameToAdd)
|
||||||
{
|
{
|
||||||
byte[] data = new byte[PACKET_SIZE - 0x20];
|
byte[] data = new byte[PACKET_SIZE - 0x20];
|
||||||
|
using (MemoryStream mem = new MemoryStream(data))
|
||||||
|
{
|
||||||
|
using (BinaryWriter binWriter = new BinaryWriter(mem))
|
||||||
|
{
|
||||||
|
binWriter.Write(Encoding.ASCII.GetBytes(sender), 0, Encoding.ASCII.GetByteCount(sender) >= 0x20 ? 0x20 : Encoding.ASCII.GetByteCount(sender));
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
return new SubPacket(OPCODE, sourceActorId, data);
|
return new SubPacket(OPCODE, sourceActorId, data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@ using System.Text;
|
||||||
|
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class RetainerResultEndPacket
|
class RetainerResultEndPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,10 +2,9 @@
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System;
|
using System;
|
||||||
using FFXIVClassic.Common;
|
using FFXIVClassic.Common;
|
||||||
using FFXIVClassic_Map_Server.packets.send.search;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace FFXIVClassic_Map_Server.packets.send.social
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
{
|
{
|
||||||
class RetainerResultUpdatePacket
|
class RetainerResultUpdatePacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1,42 @@
|
||||||
|
using FFXIVClassic.Common;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
|
{
|
||||||
|
class RetainerSearchHistoryPacket
|
||||||
|
{
|
||||||
|
public const ushort OPCODE = 0x01DD;
|
||||||
|
public const uint PACKET_SIZE = 0x120;
|
||||||
|
|
||||||
|
public static SubPacket BuildPacket(uint sourceActorId, byte count, bool hasEnded)
|
||||||
|
{
|
||||||
|
byte[] data = new byte[PACKET_SIZE - 0x20];
|
||||||
|
using (MemoryStream mem = new MemoryStream(data))
|
||||||
|
{
|
||||||
|
using (BinaryWriter binWriter = new BinaryWriter(mem))
|
||||||
|
{
|
||||||
|
binWriter.Seek(0x12, SeekOrigin.Begin);
|
||||||
|
binWriter.Write((UInt16)count);
|
||||||
|
binWriter.Write((Byte)(hasEnded ? 2 : 0));
|
||||||
|
|
||||||
|
for (int i = 0; i < count; i++)
|
||||||
|
{
|
||||||
|
binWriter.Seek(0x10 + (0x80 * i), SeekOrigin.Begin);
|
||||||
|
RetainerSearchHistoryResult result = null;
|
||||||
|
binWriter.Write((UInt32)result.timestamp);
|
||||||
|
binWriter.Write((UInt16)0);
|
||||||
|
binWriter.Write((UInt16)result.quanitiy);
|
||||||
|
binWriter.Write((UInt32)result.gilCostPerItem);
|
||||||
|
binWriter.Write((Byte)result.numStack);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return new SubPacket(OPCODE, sourceActorId, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,16 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
|
{
|
||||||
|
class RetainerSearchHistoryResult
|
||||||
|
{
|
||||||
|
public uint timestamp;
|
||||||
|
public ushort quanitiy;
|
||||||
|
public uint gilCostPerItem;
|
||||||
|
public byte numStack;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,21 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace FFXIVClassic_Map_Server.packets.send.search
|
||||||
|
{
|
||||||
|
class RetainerSearchResult
|
||||||
|
{
|
||||||
|
public uint itemId;
|
||||||
|
public uint marketWard;
|
||||||
|
public uint gilCostPerItem;
|
||||||
|
public uint quantity;
|
||||||
|
public byte numStack;
|
||||||
|
public byte quality;
|
||||||
|
public string sellerRetainerName;
|
||||||
|
public byte[] materiaType = new byte[5];
|
||||||
|
public byte[] materiaGrade = new byte[5];
|
||||||
|
}
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue