diff --git a/src/client/renderer/LevelRenderer.cpp b/src/client/renderer/LevelRenderer.cpp index 4f8c02ae..7ec623b2 100755 --- a/src/client/renderer/LevelRenderer.cpp +++ b/src/client/renderer/LevelRenderer.cpp @@ -1064,7 +1064,9 @@ std::string LevelRenderer::gatherStats1() { // std::string LevelRenderer::gatherStats2() { - return "E: " + std::to_string(renderedEntities) + "/" + std::to_string(totalEntities) + ". B: " + std::to_string(culledEntities) + ", I: " + std::to_string(((totalEntities - culledEntities) - renderedEntities)); + std::stringstream ss; + ss << "E: "<< renderedEntities << "/" << totalEntities << ". B: " << culledEntities << ", I: " << (totalEntities - culledEntities) - renderedEntities <<"\n"; + return ss.str(); } // // int[] toRender = new int[50000]; diff --git a/src/world/level/Level.cpp b/src/world/level/Level.cpp index bdc6d27f..b22a6920 100755 --- a/src/world/level/Level.cpp +++ b/src/world/level/Level.cpp @@ -1736,7 +1736,9 @@ void Level::extinguishFire(int x, int y, int z, int face) { } } std::string Level::gatherStats() { - return "All: " + std::to_string(entities.size()); + std::stringstream ss; + ss << "All: " << entities.size(); + return ss.str(); } std::string Level::gatherChunkSourceStats() { diff --git a/src/world/level/chunk/ChunkCache.h b/src/world/level/chunk/ChunkCache.h index 24d93f45..f6e53767 100755 --- a/src/world/level/chunk/ChunkCache.h +++ b/src/world/level/chunk/ChunkCache.h @@ -194,7 +194,9 @@ public: std::string gatherStats() { // return "ChunkCache: 1024"; - return ("ChunkCache: " + std::to_string(CHUNK_CACHE_WIDTH * CHUNK_CACHE_WIDTH)); + std::stringstream ss; + ss << "ChunkCache: " << CHUNK_CACHE_WIDTH * CHUNK_CACHE_WIDTH; + return ss.str(); } void saveAll(bool onlyUnsaved) {