aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.World/DataOutputStream.cpp
diff options
context:
space:
mode:
authorvoid_17 <heroerror3@gmail.com>2026-03-02 15:53:32 +0700
committervoid_17 <heroerror3@gmail.com>2026-03-02 15:53:32 +0700
commitd63f79325f85e014361eb8cf1e41eaebedb1ae71 (patch)
treed9f28714afd516bc2450f33b0a77c5e05ff4de90 /Minecraft.World/DataOutputStream.cpp
parentd6ec138710461294c3ffd2723bc8a9f212d3471f (diff)
Get rid of MSVC's __int64
Use either int64_t, uint64_t or long long and unsigned long long, defined as per C++11 standard
Diffstat (limited to 'Minecraft.World/DataOutputStream.cpp')
-rw-r--r--Minecraft.World/DataOutputStream.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/Minecraft.World/DataOutputStream.cpp b/Minecraft.World/DataOutputStream.cpp
index 8e277c23..ede943d2 100644
--- a/Minecraft.World/DataOutputStream.cpp
+++ b/Minecraft.World/DataOutputStream.cpp
@@ -78,7 +78,7 @@ void DataOutputStream::writeByte(byte a)
//v - a double value to be written.
void DataOutputStream::writeDouble(double a)
{
- __int64 bits = Double::doubleToLongBits( a );
+ int64_t bits = Double::doubleToLongBits( a );
writeLong( bits );
// TODO 4J Stu - Error handling?
@@ -116,7 +116,7 @@ void DataOutputStream::writeInt(int a)
//In no exception is thrown, the counter written is incremented by 8.
//Parameters:
//v - a long to be written.
-void DataOutputStream::writeLong(__int64 a)
+void DataOutputStream::writeLong(int64_t a)
{
stream->write( (a >> 56) & 0xff );
stream->write( (a >> 48) & 0xff );
@@ -178,7 +178,7 @@ void DataOutputStream::writeBoolean(bool b)
{
stream->write( b ? (byte)1 : (byte)0 );
// TODO 4J Stu - Error handling?
- written += 1;
+ written += 1;
}
//Writes a string to the underlying output stream using modified UTF-8 encoding in a machine-independent manner.
@@ -220,7 +220,7 @@ void DataOutputStream::writeUTF(const wstring& str)
byteArray bytearr(utflen+2);
bytearr[count++] = (byte) ((utflen >> 8) & 0xFF);
- bytearr[count++] = (byte) ((utflen >> 0) & 0xFF);
+ bytearr[count++] = (byte) ((utflen >> 0) & 0xFF);
int i=0;
for (i=0; i<strlen; i++)