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.
This commit is contained in:
void_17
2026-03-02 15:58:20 +07:00
parent d63f79325f
commit 7074f35e4b
1373 changed files with 12054 additions and 12054 deletions

View File

@@ -6,12 +6,12 @@
SetCarriedItemPacket::SetCarriedItemPacket()
SetCarriedItemPacket::SetCarriedItemPacket()
{
slot = 0;
}
SetCarriedItemPacket::SetCarriedItemPacket(int slot)
SetCarriedItemPacket::SetCarriedItemPacket(int slot)
{
this->slot = slot;
}
@@ -21,27 +21,27 @@ void SetCarriedItemPacket::read(DataInputStream *dis) //throws IOException
slot = dis->readShort();
}
void SetCarriedItemPacket::write(DataOutputStream *dos) //throws IOException
void SetCarriedItemPacket::write(DataOutputStream *dos) //throws IOException
{
dos->writeShort(slot);
}
void SetCarriedItemPacket::handle(PacketListener *listener)
void SetCarriedItemPacket::handle(PacketListener *listener)
{
listener->handleSetCarriedItem(shared_from_this());
}
int SetCarriedItemPacket::getEstimatedSize()
int SetCarriedItemPacket::getEstimatedSize()
{
return 2;
}
bool SetCarriedItemPacket::canBeInvalidated()
bool SetCarriedItemPacket::canBeInvalidated()
{
return true;
}
bool SetCarriedItemPacket::isInvalidatedBy(shared_ptr<Packet> packet)
bool SetCarriedItemPacket::isInvalidatedBy(std::shared_ptr<Packet> packet)
{
return true;
}