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/ClientSideMerchant.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Minecraft.World/ClientSideMerchant.cpp') diff --git a/Minecraft.World/ClientSideMerchant.cpp b/Minecraft.World/ClientSideMerchant.cpp index 5d021c22..9719cd48 100644 --- a/Minecraft.World/ClientSideMerchant.cpp +++ b/Minecraft.World/ClientSideMerchant.cpp @@ -3,10 +3,10 @@ #include "net.minecraft.world.inventory.h" #include "ClientSideMerchant.h" -ClientSideMerchant::ClientSideMerchant(shared_ptr source, int name) +ClientSideMerchant::ClientSideMerchant(std::shared_ptr source, int name) { this->source = source; - // 4J Stu - Need to do this after creating as a shared_ptr + // 4J Stu - Need to do this after creating as a std::shared_ptr container = NULL; //new MerchantContainer(source, this); currentOffers = NULL; m_name = name; @@ -28,17 +28,17 @@ Container *ClientSideMerchant::getContainer() return container; } -shared_ptr ClientSideMerchant::getTradingPlayer() +std::shared_ptr ClientSideMerchant::getTradingPlayer() { return source; } -void ClientSideMerchant::setTradingPlayer(shared_ptr player) +void ClientSideMerchant::setTradingPlayer(std::shared_ptr player) { } -MerchantRecipeList *ClientSideMerchant::getOffers(shared_ptr forPlayer) +MerchantRecipeList *ClientSideMerchant::getOffers(std::shared_ptr forPlayer) { return currentOffers; } @@ -54,7 +54,7 @@ void ClientSideMerchant::notifyTrade(MerchantRecipe *activeRecipe) activeRecipe->increaseUses(); } -void ClientSideMerchant::notifyTradeUpdated(shared_ptr item) +void ClientSideMerchant::notifyTradeUpdated(std::shared_ptr item) { } -- cgit v1.2.3