summaryrefslogtreecommitdiffstats
path: root/src/Protocol
diff options
context:
space:
mode:
Diffstat (limited to 'src/Protocol')
-rw-r--r--src/Protocol/Protocol_1_8.cpp2
-rw-r--r--src/Protocol/Protocol_1_8.h2
-rw-r--r--src/Protocol/Protocol_1_9.cpp20
-rw-r--r--src/Protocol/Protocol_1_9.h4
4 files changed, 2 insertions, 26 deletions
diff --git a/src/Protocol/Protocol_1_8.cpp b/src/Protocol/Protocol_1_8.cpp
index ee72e14fb..39c20b6cf 100644
--- a/src/Protocol/Protocol_1_8.cpp
+++ b/src/Protocol/Protocol_1_8.cpp
@@ -3172,7 +3172,7 @@ void cProtocol_1_8_0::StartEncryption(const Byte * a_Key)
-eBlockFace cProtocol_1_8_0::FaceIntToBlockFace(Int8 a_BlockFace)
+eBlockFace cProtocol_1_8_0::FaceIntToBlockFace(const Int32 a_BlockFace)
{
// Normalize the blockface values returned from the protocol
// Anything known gets mapped 1:1, everything else returns BLOCK_FACE_NONE
diff --git a/src/Protocol/Protocol_1_8.h b/src/Protocol/Protocol_1_8.h
index b813b16bf..f48ed4f9c 100644
--- a/src/Protocol/Protocol_1_8.h
+++ b/src/Protocol/Protocol_1_8.h
@@ -226,7 +226,7 @@ protected:
/** Converts the BlockFace received by the protocol into eBlockFace constants.
If the received value doesn't match any of our eBlockFace constants, BLOCK_FACE_NONE is returned. */
- eBlockFace FaceIntToBlockFace(Int8 a_FaceInt);
+ eBlockFace FaceIntToBlockFace(Int32 a_FaceInt);
/** Sends the entity type and entity-dependent data required for the entity to initially spawn. */
virtual void SendEntitySpawn(const cEntity & a_Entity, const UInt8 a_ObjectType, const Int32 a_ObjectData);
diff --git a/src/Protocol/Protocol_1_9.cpp b/src/Protocol/Protocol_1_9.cpp
index 3d34eeabe..b4fc47d0f 100644
--- a/src/Protocol/Protocol_1_9.cpp
+++ b/src/Protocol/Protocol_1_9.cpp
@@ -1233,26 +1233,6 @@ void cProtocol_1_9_0::ParseItemMetadata(cItem & a_Item, const AString & a_Metada
-eBlockFace cProtocol_1_9_0::FaceIntToBlockFace(Int32 a_BlockFace)
-{
- // Normalize the blockface values returned from the protocol
- // Anything known gets mapped 1:1, everything else returns BLOCK_FACE_NONE
- switch (a_BlockFace)
- {
- case BLOCK_FACE_XM: return BLOCK_FACE_XM;
- case BLOCK_FACE_XP: return BLOCK_FACE_XP;
- case BLOCK_FACE_YM: return BLOCK_FACE_YM;
- case BLOCK_FACE_YP: return BLOCK_FACE_YP;
- case BLOCK_FACE_ZM: return BLOCK_FACE_ZM;
- case BLOCK_FACE_ZP: return BLOCK_FACE_ZP;
- default: return BLOCK_FACE_NONE;
- }
-}
-
-
-
-
-
eHand cProtocol_1_9_0::HandIntToEnum(Int32 a_Hand)
{
// Convert hand parameter into eHand enum
diff --git a/src/Protocol/Protocol_1_9.h b/src/Protocol/Protocol_1_9.h
index e936710d7..5e444c4e1 100644
--- a/src/Protocol/Protocol_1_9.h
+++ b/src/Protocol/Protocol_1_9.h
@@ -97,10 +97,6 @@ protected:
/** Parses item metadata as read by ReadItem(), into the item enchantments. */
virtual void ParseItemMetadata(cItem & a_Item, const AString & a_Metadata) override;
- /** Converts the BlockFace received by the protocol into eBlockFace constants.
- If the received value doesn't match any of our eBlockFace constants, BLOCK_FACE_NONE is returned. */
- eBlockFace FaceIntToBlockFace(Int32 a_FaceInt);
-
/** Converts the hand parameter received by the protocol into eHand constants.
If the received value doesn't match any of the know value, raise an assertion fail or return hMain. */
eHand HandIntToEnum(Int32 a_Hand);