mirror of
https://git.neolegacy.dev/neoStudiosLCE/neoLegacy.git
synced 2026-11-21 17:23:56 +01:00
fix estimated entity packet size
This commit is contained in:
1 parent
e5ee0a72b4
commit
7d9e12501c
1 file changed
+7
-1
@@ -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);
|
||||
}
|
||||
Reference in new issue
Block a user