forked from marcosvf132/TibiaAPI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLook.cs
More file actions
35 lines (29 loc) · 959 Bytes
/
Look.cs
File metadata and controls
35 lines (29 loc) · 959 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
using OXGaming.TibiaAPI.Constants;
using OXGaming.TibiaAPI.Utilities;
namespace OXGaming.TibiaAPI.Network.ClientPackets
{
public class Look : ClientPacket
{
public Position Position { get; set; }
public ushort ObjectId { get; set; }
public byte StackPosition { get; set; }
public Look(Client client)
{
Client = client;
PacketType = ClientPacketType.Look;
}
public override void ParseFromNetworkMessage(NetworkMessage message)
{
Position = message.ReadPosition();
ObjectId = message.ReadUInt16();
StackPosition = message.ReadByte();
}
public override void AppendToNetworkMessage(NetworkMessage message)
{
message.Write((byte)ClientPacketType.Look);
message.Write(Position);
message.Write(ObjectId);
message.Write(StackPosition);
}
}
}