fix estimated entity packet size

This commit is contained in:
DrPerkyLegit committed 2026-10-30 15:36:21 -04:00
1 parent e5ee0a72b4
commit 7d9e12501c
1 file changed
+7 -1
+7 -1
View File
@@ -107,5 +107,11 @@ void AddEntityPacket::handle(PacketListener *listener)
int AddEntityPacket::getEstimatedSize()
{
return (11 + data > -1 ? 6 : 0) + 2;
#ifdef _LARGE_WORLDS
int posSize = 4 + 4 + 4;
#else
int posSize = 2 + 2 + 2;
#endif
return 4 + 1 + posSize + 1 + 1 + 4 + (data > -1 ? (2 + 2 + 2) : 0);
}