summaryrefslogtreecommitdiffstats
path: root/src/Protocol
diff options
context:
space:
mode:
authorAlexander Harkness <me@bearbin.net>2020-08-06 13:36:13 +0200
committerAlexander Harkness <me@bearbin.net>2020-08-06 13:36:41 +0200
commitb45d8bfc1e207c87acf7f524329dd02b9ea84be5 (patch)
treeef6e67a1832346c10ef4fc9fc107d69aeb5edeec /src/Protocol
parentUpdate bed behavior (#4545) (diff)
downloadcuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar.gz
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar.bz2
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar.lz
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar.xz
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.tar.zst
cuberite-b45d8bfc1e207c87acf7f524329dd02b9ea84be5.zip
Diffstat (limited to '')
-rw-r--r--src/Protocol/Protocol_1_12.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Protocol/Protocol_1_12.cpp b/src/Protocol/Protocol_1_12.cpp
index 1f136148e..a67a82eaf 100644
--- a/src/Protocol/Protocol_1_12.cpp
+++ b/src/Protocol/Protocol_1_12.cpp
@@ -980,7 +980,7 @@ void cProtocol_1_12::HandleCraftRecipe(cByteBuffer & a_ByteBuffer)
auto CuberiteRecipeId = cRoot::Get()->GetRecipeMapper()->GetCuberiteRecipeId(RecipeID, m_Client->GetProtocolVersion());
if (CuberiteRecipeId.has_value())
{
- m_Client->HandleCraftRecipe(*CuberiteRecipeId);
+ m_Client->HandleCraftRecipe(CuberiteRecipeId.value());
}
}
@@ -1320,7 +1320,7 @@ void cProtocol_1_12_2::SendUnlockRecipe(UInt32 a_RecipeID)
Pkt.WriteBool(true);
Pkt.WriteBool(false);
Pkt.WriteVarInt32(1);
- Pkt.WriteVarInt32(*ProtocolRecipeId);
+ Pkt.WriteVarInt32(ProtocolRecipeId.value());
}
}
@@ -1350,8 +1350,8 @@ void cProtocol_1_12_2::SendInitRecipes(UInt32 a_RecipeID)
else
{
Pkt.WriteVarInt32(1);
- Pkt.WriteVarInt32(*ProtocolRecipeId);
+ Pkt.WriteVarInt32(ProtocolRecipeId.value());
Pkt.WriteVarInt32(1);
- Pkt.WriteVarInt32(*ProtocolRecipeId);
+ Pkt.WriteVarInt32(ProtocolRecipeId.value());
}
}