summaryrefslogtreecommitdiffstats
path: root/src/UI/EnchantingWindow.h
diff options
context:
space:
mode:
authorKingCol13 <48412633+KingCol13@users.noreply.github.com>2020-10-01 23:33:32 +0200
committerGitHub <noreply@github.com>2020-10-01 23:33:32 +0200
commit8947147c25e2640519897bfdc8807e97ee291d70 (patch)
tree63eca1e5bd8ad29ac9beba5a780d466c9bb13849 /src/UI/EnchantingWindow.h
parentAdd SetBlockMeta warning in documentation (#4943) (diff)
downloadcuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar.gz
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar.bz2
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar.lz
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar.xz
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.tar.zst
cuberite-8947147c25e2640519897bfdc8807e97ee291d70.zip
Diffstat (limited to '')
-rw-r--r--src/UI/EnchantingWindow.h23
1 files changed, 15 insertions, 8 deletions
diff --git a/src/UI/EnchantingWindow.h b/src/UI/EnchantingWindow.h
index 4de5ed00c..2b32f078a 100644
--- a/src/UI/EnchantingWindow.h
+++ b/src/UI/EnchantingWindow.h
@@ -15,6 +15,12 @@
+class cSlotAreaEnchanting;
+
+
+
+
+
class cEnchantingWindow:
public cWindow
{
@@ -24,22 +30,23 @@ public:
cEnchantingWindow(Vector3i a_BlockPos, const AString & a_Title);
+ /** Sends enchantment properties to the client.
+ If the property represents a level requirement, stores it for later GetProperty retrieval. */
virtual void SetProperty(short a_Property, short a_Value, cPlayer & a_Player) override;
+ /** Sends enchantment properties to the client.
+ If the property represents a level requirement, stores it for later GetProperty retrieval. */
virtual void SetProperty(short a_Property, short a_Value) override;
- /** Return the value of a property */
- short GetPropertyValue(short a_Property);
+ /** Return the level requirement of the given enchantment slot. */
+ short GetProperty(short a_Property);
virtual void DistributeStack(cItem & a_ItemStack, int a_Slot, cPlayer & a_Player, cSlotArea * a_ClickedArea, bool a_ShouldApply) override;
- cSlotArea * m_SlotArea;
+ cSlotAreaEnchanting * m_SlotArea;
protected:
- short m_PropertyValue[3];
+
+ std::array<short, 3> m_PropertyValue;
Vector3i m_BlockPos;
};
-
-
-
-