Use BYTE Win Typedef instead of byte typedef from Minecraft.World

"byte" wasnt working anymore for some reason
This commit is contained in:
GabsPuNs
2026-04-13 17:54:28 -04:00
parent e90e585ef0
commit 40d48948ff
233 changed files with 4751 additions and 930 deletions

View File

@@ -2,14 +2,14 @@
#include "ByteArrayOutputStream.h"
// Creates a new byte array output stream. The buffer capacity is initially 32 bytes, though its size increases if necessary.
// Creates a new BYTE array output stream. The buffer capacity is initially 32 bytes, though its size increases if necessary.
ByteArrayOutputStream::ByteArrayOutputStream()
{
count = 0;
buf = byteArray(32);
}
// Creates a new byte array output stream, with a buffer capacity of the specified size, in bytes.
// Creates a new BYTE array output stream, with a buffer capacity of the specified size, in bytes.
// Parameters:
// size - the initial size.
ByteArrayOutputStream::ByteArrayOutputStream(unsigned int size)
@@ -26,9 +26,9 @@ ByteArrayOutputStream::~ByteArrayOutputStream()
}
}
// Writes the specified byte to this byte array output stream.
// Writes the specified BYTE to this BYTE array output stream.
// Parameters:
// b - the byte to be written.
// b - the BYTE to be written.
void ByteArrayOutputStream::write(unsigned int b)
{
// If we will fill the buffer we need to make it bigger
@@ -37,18 +37,18 @@ void ByteArrayOutputStream::write(unsigned int b)
buf.resize(buf.length * 2);
}
buf[count] = (byte)b;
buf[count] = (BYTE)b;
count++;
}
// Writes b.length bytes from the specified byte array to this output stream.
// Writes b.length bytes from the specified BYTE array to this output stream.
// The general contract for write(b) is that it should have exactly the same effect as the call write(b, 0, b.length).
void ByteArrayOutputStream::write(byteArray b)
{
write(b, 0, b.length);
}
// Writes len bytes from the specified byte array starting at offset off to this byte array output stream.
// Writes len bytes from the specified BYTE array starting at offset off to this BYTE array output stream.
// Parameters:
// b - the data.
// off - the start offset in the data.
@@ -88,9 +88,9 @@ void ByteArrayOutputStream::close()
{
}
// Creates a newly allocated byte array. Its size is the current size of this output stream and the valid contents of the buffer have been copied into it.
// Creates a newly allocated BYTE array. Its size is the current size of this output stream and the valid contents of the buffer have been copied into it.
// Returns:
// the current contents of this output stream, as a byte array.
// the current contents of this output stream, as a BYTE array.
byteArray ByteArrayOutputStream::toByteArray()
{
byteArray out(count);