summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaG1924 <12997935+LaG1924@users.noreply.github.com>2018-02-03 12:52:09 +0100
committerLaG1924 <12997935+LaG1924@users.noreply.github.com>2018-02-03 12:52:09 +0100
commit3cca73c64720fdc48c20653e00c8dfe89d27dd4f (patch)
treefcb92cc9c8ed772c620c728a19dea5ba521ee101
parentBackported to CMake 3.5 (diff)
downloadAltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar.gz
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar.bz2
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar.lz
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar.xz
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.tar.zst
AltCraft-3cca73c64720fdc48c20653e00c8dfe89d27dd4f.zip
Diffstat (limited to '')
-rw-r--r--src/Packet.hpp32
1 files changed, 27 insertions, 5 deletions
diff --git a/src/Packet.hpp b/src/Packet.hpp
index 57b39af..1920ea6 100644
--- a/src/Packet.hpp
+++ b/src/Packet.hpp
@@ -521,7 +521,7 @@ struct PacketUpdateHealth : Packet {
struct PacketSpawnObject : Packet {
void ToStream(StreamOutput *stream) override {
-
+
}
void FromStream(StreamInput *stream) override {
@@ -545,7 +545,7 @@ struct PacketSpawnObject : Packet {
int EntityId;
Uuid ObjectUuid;
- unsigned char Type;
+ unsigned char Type;
double X, Y, Z;
unsigned char Pitch, Yaw;
int Data;
@@ -693,7 +693,7 @@ struct PacketSpawnPlayer : Packet {
Uuid PlayerUuid;
double X, Y, Z;
unsigned char Yaw, Pitch;
-
+
};
@@ -992,7 +992,7 @@ struct PacketClickWindow : Packet {
}
void FromStream(StreamInput *stream) override {
-
+
}
int GetPacketId() override {
@@ -1028,7 +1028,7 @@ struct PacketCloseWindowSB : Packet {
struct PacketDisconnect : Packet {
void ToStream(StreamOutput *stream) override {
-
+
}
void FromStream(StreamInput *stream) override {
@@ -1092,4 +1092,26 @@ struct PacketChatMessageSB : Packet {
std::string Message;
PacketChatMessageSB(const std::string msg) : Message(msg) {};
+};
+
+struct PacketPlayerDigging : Packet {
+ void ToStream(StreamOutput *stream) override {
+ stream->WriteVarInt(Status);
+ stream->WritePosition(Location);
+ stream->WriteByte(Face);
+ }
+
+ void FromStream(StreamInput *stream) override {
+
+ }
+
+ int GetPacketId() override {
+ return PacketNamePlaySB::PlayerDigging;
+ }
+
+ int Status;
+ Vector Location;
+ signed char Face;
+
+ PacketPlayerDigging(int status, const Vector& location, signed char face) : Status(status),Location(location),Face(face) {};
}; \ No newline at end of file