refactor(Minecraft.World): Implement LCEMP changes.

This commit is contained in:
2026-07-13 00:14:53 +03:00
parent 3fce0538c5
commit 21e2add09a
64 changed files with 655 additions and 372 deletions
+12 -2
View File
@@ -37,9 +37,19 @@ void TexturePacket::handle(PacketListener *listener)
void TexturePacket::read(DataInputStream *dis) //throws IOException
{
textureName = dis->readUTF();
dwBytes = (DWORD)dis->readShort();
short rawBytes = dis->readShort();
if(rawBytes <= 0)
{
dwBytes = 0;
return;
}
dwBytes = (DWORD)(unsigned short)rawBytes;
if(dwBytes > 65536)
{
dwBytes = 0;
return;
}
if(dwBytes>0)
{
this->pbData= new BYTE [dwBytes];