From 7074f35e4ba831e358117842b99ee35b87f85ae5 Mon Sep 17 00:00:00 2001 From: void_17 Date: Mon, 2 Mar 2026 15:58:20 +0700 Subject: shared_ptr -> std::shared_ptr This is one of the first commits in a plan to remove all `using namespace std;` lines in the entire codebase as it is considered anti-pattern today. --- Minecraft.World/WeaponItem.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'Minecraft.World/WeaponItem.h') diff --git a/Minecraft.World/WeaponItem.h b/Minecraft.World/WeaponItem.h index 2150f6e9..162866d6 100644 --- a/Minecraft.World/WeaponItem.h +++ b/Minecraft.World/WeaponItem.h @@ -12,17 +12,17 @@ private: public: WeaponItem(int id, const Tier *tier); - virtual float getDestroySpeed(shared_ptr itemInstance, Tile *tile); - virtual bool hurtEnemy(shared_ptr itemInstance, shared_ptr mob, shared_ptr attacker); - virtual bool mineBlock(shared_ptr itemInstance, Level *level, int tile, int x, int y, int z, shared_ptr owner); - virtual int getAttackDamage(shared_ptr entity); + virtual float getDestroySpeed(std::shared_ptr itemInstance, Tile *tile); + virtual bool hurtEnemy(std::shared_ptr itemInstance, std::shared_ptr mob, std::shared_ptr attacker); + virtual bool mineBlock(std::shared_ptr itemInstance, Level *level, int tile, int x, int y, int z, std::shared_ptr owner); + virtual int getAttackDamage(std::shared_ptr entity); virtual bool isHandEquipped(); - virtual UseAnim getUseAnimation(shared_ptr itemInstance); - virtual int getUseDuration(shared_ptr itemInstance); - virtual shared_ptr use(shared_ptr instance, Level *level, shared_ptr player); + virtual UseAnim getUseAnimation(std::shared_ptr itemInstance); + virtual int getUseDuration(std::shared_ptr itemInstance); + virtual std::shared_ptr use(std::shared_ptr instance, Level *level, std::shared_ptr player); virtual bool canDestroySpecial(Tile *tile); virtual int getEnchantmentValue(); const Tier *getTier(); - bool isValidRepairItem(shared_ptr source, shared_ptr repairItem); + bool isValidRepairItem(std::shared_ptr source, std::shared_ptr repairItem); }; \ No newline at end of file -- cgit v1.2.3