aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.World/ChunkStorageProfileDecorator.cpp
diff options
context:
space:
mode:
authorqwasdrizzel <145519042+qwasdrizzel@users.noreply.github.com>2026-03-16 21:44:26 -0500
committerGitHub <noreply@github.com>2026-03-16 21:44:26 -0500
commitce739f6045ec72127491286ea3f3f21e537c1b55 (patch)
treef33bd42a47c1b4a7b2153a7fb77127ee3b407db9 /Minecraft.World/ChunkStorageProfileDecorator.cpp
parent255a18fe8e9b57377975f82e2b227afe2a12eda0 (diff)
parent5a59f5d146b43811dde6a5a0245ee9875d7b5cd1 (diff)
Merge branch 'smartcmd:main' into main
Diffstat (limited to 'Minecraft.World/ChunkStorageProfileDecorator.cpp')
-rw-r--r--Minecraft.World/ChunkStorageProfileDecorator.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Minecraft.World/ChunkStorageProfileDecorator.cpp b/Minecraft.World/ChunkStorageProfileDecorator.cpp
index 76ffddbc..375048db 100644
--- a/Minecraft.World/ChunkStorageProfileDecorator.cpp
+++ b/Minecraft.World/ChunkStorageProfileDecorator.cpp
@@ -10,7 +10,7 @@ ChunkStorageProfilerDecorator::ChunkStorageProfilerDecorator(ChunkStorage *capsu
LevelChunk *ChunkStorageProfilerDecorator::load(Level *level, int x, int z)
{
- __int64 nanoTime = System::nanoTime();
+ int64_t nanoTime = System::nanoTime();
LevelChunk *chunk = capsulated->load(level, x, z);
timeSpentLoading += System::nanoTime() - nanoTime;
loadCount++;
@@ -20,7 +20,7 @@ LevelChunk *ChunkStorageProfilerDecorator::load(Level *level, int x, int z)
void ChunkStorageProfilerDecorator::save(Level *level, LevelChunk *levelChunk)
{
- __int64 nanoTime = System::nanoTime();
+ int64_t nanoTime = System::nanoTime();
capsulated->save(level, levelChunk);
timeSpentSaving += System::nanoTime() - nanoTime;
saveCount++;
@@ -45,7 +45,7 @@ void ChunkStorageProfilerDecorator::tick()
#ifdef __PSVITA__
sprintf(buf,"Average load time: %f (%lld)",0.000001 * (double) timeSpentLoading / (double) loadCount, loadCount);
#else
- sprintf(buf,"Average load time: %f (%I64d)",0.000001 * (double) timeSpentLoading / (double) loadCount, loadCount);
+ sprintf(buf,"Average load time: %f (%I64d)",0.000001 * static_cast<double>(timeSpentLoading) / static_cast<double>(loadCount), loadCount);
#endif
app.DebugPrintf(buf);
#endif
@@ -56,10 +56,10 @@ void ChunkStorageProfilerDecorator::tick()
#ifdef __PSVITA__
sprintf(buf,"Average save time: %f (%lld)",0.000001 * (double) timeSpentSaving / (double) loadCount, loadCount);
#else
- sprintf(buf,"Average save time: %f (%I64d)",0.000001 * (double) timeSpentSaving / (double) loadCount, loadCount);
+ sprintf(buf,"Average save time: %f (%I64d)",0.000001 * static_cast<double>(timeSpentSaving) / static_cast<double>(loadCount), loadCount);
#endif
app.DebugPrintf(buf);
-#endif
+#endif
}
counter = 0;
}