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/SetHealthPacket.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Minecraft.World/SetHealthPacket.cpp') diff --git a/Minecraft.World/SetHealthPacket.cpp b/Minecraft.World/SetHealthPacket.cpp index 55d7ccc3..63e1a593 100644 --- a/Minecraft.World/SetHealthPacket.cpp +++ b/Minecraft.World/SetHealthPacket.cpp @@ -25,7 +25,7 @@ SetHealthPacket::SetHealthPacket(int health, int food, float saturation, ETeleme this->damageSource = damageSource; } -void SetHealthPacket::read(DataInputStream *dis) //throws IOException +void SetHealthPacket::read(DataInputStream *dis) //throws IOException { health = dis->readShort(); food = dis->readShort(); @@ -35,7 +35,7 @@ void SetHealthPacket::read(DataInputStream *dis) //throws IOException damageSource = (ETelemetryChallenges)dis->readByte(); } -void SetHealthPacket::write(DataOutputStream *dos) //throws IOException +void SetHealthPacket::write(DataOutputStream *dos) //throws IOException { dos->writeShort(health); dos->writeShort(food); @@ -45,7 +45,7 @@ void SetHealthPacket::write(DataOutputStream *dos) //throws IOException dos->writeByte(damageSource); } -void SetHealthPacket::handle(PacketListener *listener) +void SetHealthPacket::handle(PacketListener *listener) { listener->handleSetHealth(shared_from_this()); } @@ -60,7 +60,7 @@ bool SetHealthPacket::canBeInvalidated() return true; } -bool SetHealthPacket::isInvalidatedBy(shared_ptr packet) +bool SetHealthPacket::isInvalidatedBy(std::shared_ptr packet) { return true; } \ No newline at end of file -- cgit v1.2.3