mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-10 22:44:36 +02:00
Initial Commit.
This commit is contained in:
commit
46c4c26d01
82 changed files with 70188 additions and 0 deletions
33
FFXIVClassic Map Server/packets/receive/HandshakePacket.cs
Normal file
33
FFXIVClassic Map Server/packets/receive/HandshakePacket.cs
Normal file
|
@ -0,0 +1,33 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FFXIVClassic_Map_Server.packets.receive
|
||||
{
|
||||
class HandshakePacket
|
||||
{
|
||||
bool invalidPacket = false;
|
||||
|
||||
public uint actorID;
|
||||
|
||||
public HandshakePacket(byte[] data)
|
||||
{
|
||||
using (MemoryStream mem = new MemoryStream(data))
|
||||
{
|
||||
using (BinaryReader binReader = new BinaryReader(mem))
|
||||
{
|
||||
try{
|
||||
binReader.BaseStream.Seek(4, SeekOrigin.Begin);
|
||||
actorID = UInt32.Parse(Encoding.ASCII.GetString(binReader.ReadBytes(10)));
|
||||
}
|
||||
catch (Exception){
|
||||
invalidPacket = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue