aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.World/BowItem.h
diff options
context:
space:
mode:
authordaoge_cmd <3523206925@qq.com>2026-03-01 12:16:08 +0800
committerdaoge_cmd <3523206925@qq.com>2026-03-01 12:16:08 +0800
commitb691c43c44ff180d10e7d4a9afc83b98551ff586 (patch)
tree3e9849222cbc6ba49f2f1fc6e5fe7179632c7390 /Minecraft.World/BowItem.h
parentdef8cb415354ac390b7e89052a50605285f1aca9 (diff)
Initial commit
Diffstat (limited to 'Minecraft.World/BowItem.h')
-rw-r--r--Minecraft.World/BowItem.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/Minecraft.World/BowItem.h b/Minecraft.World/BowItem.h
new file mode 100644
index 00000000..b4eba111
--- /dev/null
+++ b/Minecraft.World/BowItem.h
@@ -0,0 +1,31 @@
+#pragma once
+
+#include "Item.h"
+
+class Player;
+class Level;
+
+class BowItem : public Item
+{
+public:
+ static const wstring TEXTURE_PULL[];
+ static const int MAX_DRAW_DURATION = 20 * 1;
+
+private:
+ static const int BOW_ICONS_COUNT = 3;
+ Icon **icons;
+
+public:
+ BowItem(int id);
+
+ virtual void releaseUsing(shared_ptr<ItemInstance> itemInstance, Level *level, shared_ptr<Player> player, int durationLeft);
+ virtual shared_ptr<ItemInstance> useTimeDepleted(shared_ptr<ItemInstance> instance, Level *level, shared_ptr<Player> player);
+ virtual int getUseDuration(shared_ptr<ItemInstance> itemInstance);
+ virtual UseAnim getUseAnimation(shared_ptr<ItemInstance> itemInstance);
+ virtual shared_ptr<ItemInstance> use(shared_ptr<ItemInstance> instance, Level *level, shared_ptr<Player> player);
+ virtual int getEnchantmentValue();
+
+ //@Override
+ void registerIcons(IconRegister *iconRegister);
+ Icon *getDrawnIcon(int amount);
+}; \ No newline at end of file