diff options
| author | void_17 <heroerror3@gmail.com> | 2026-03-02 17:37:16 +0700 |
|---|---|---|
| committer | void_17 <heroerror3@gmail.com> | 2026-03-02 17:37:16 +0700 |
| commit | 119bff351450ea16ffda550b6e0f67379b29f708 (patch) | |
| tree | d9f28714afd516bc2450f33b0a77c5e05ff4de90 /Minecraft.World/AddEntityPacket.cpp | |
| parent | 8a2a62ea1d47364f802cf9aae97668bc4a7007b5 (diff) | |
Revert "shared_ptr -> std::shared_ptr"
This reverts commit 7074f35e4ba831e358117842b99ee35b87f85ae5.
Diffstat (limited to 'Minecraft.World/AddEntityPacket.cpp')
| -rw-r--r-- | Minecraft.World/AddEntityPacket.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Minecraft.World/AddEntityPacket.cpp b/Minecraft.World/AddEntityPacket.cpp index 9263bfda..6231537d 100644 --- a/Minecraft.World/AddEntityPacket.cpp +++ b/Minecraft.World/AddEntityPacket.cpp @@ -8,7 +8,7 @@ -void AddEntityPacket::_init(std::shared_ptr<Entity> e, int type, int data, int xp, int yp, int zp, int yRotp, int xRotp) +void AddEntityPacket::_init(shared_ptr<Entity> e, int type, int data, int xp, int yp, int zp, int yRotp, int xRotp) { id = e->entityId; // 4J Stu - We should add entities at their "last sent" position so that the relative update packets @@ -38,16 +38,16 @@ void AddEntityPacket::_init(std::shared_ptr<Entity> e, int type, int data, int x } } -AddEntityPacket::AddEntityPacket() +AddEntityPacket::AddEntityPacket() { } -AddEntityPacket::AddEntityPacket(std::shared_ptr<Entity> e, int type, int yRotp, int xRotp, int xp, int yp, int zp ) +AddEntityPacket::AddEntityPacket(shared_ptr<Entity> e, int type, int yRotp, int xRotp, int xp, int yp, int zp ) { _init(e, type, -1, xp, yp, zp, yRotp, xRotp); // 4J - changed "no data" value to be -1, we can have a valid entity id of 0 } -AddEntityPacket::AddEntityPacket(std::shared_ptr<Entity> e, int type, int data, int yRotp, int xRotp, int xp, int yp, int zp ) +AddEntityPacket::AddEntityPacket(shared_ptr<Entity> e, int type, int data, int yRotp, int xRotp, int xp, int yp, int zp ) { _init(e, type, data, xp, yp, zp, yRotp, xRotp); } @@ -100,12 +100,12 @@ void AddEntityPacket::write(DataOutputStream *dos) // throws IOException TODO 4J } } -void AddEntityPacket::handle(PacketListener *listener) +void AddEntityPacket::handle(PacketListener *listener) { listener->handleAddEntity(shared_from_this()); } -int AddEntityPacket::getEstimatedSize() +int AddEntityPacket::getEstimatedSize() { return 11 + data > -1 ? 6 : 0; } |
