summaryrefslogtreecommitdiffstats
path: root/src/WorldStorage/StatisticsSerializer.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@outlook.com>2021-05-04 17:11:56 +0200
committerTiger Wang <ziwei.tiger@outlook.com>2021-05-04 17:11:56 +0200
commit34bf5c0d9db195edf8b576d1273876966cf650b2 (patch)
treeb9682f8226fef09d3625089ba06235f93ce5c976 /src/WorldStorage/StatisticsSerializer.h
parentAdd player statistics to API (#5193) (diff)
downloadcuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar.gz
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar.bz2
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar.lz
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar.xz
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.tar.zst
cuberite-34bf5c0d9db195edf8b576d1273876966cf650b2.zip
Diffstat (limited to 'src/WorldStorage/StatisticsSerializer.h')
-rw-r--r--src/WorldStorage/StatisticsSerializer.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/WorldStorage/StatisticsSerializer.h b/src/WorldStorage/StatisticsSerializer.h
new file mode 100644
index 000000000..1ccc55dbd
--- /dev/null
+++ b/src/WorldStorage/StatisticsSerializer.h
@@ -0,0 +1,30 @@
+
+// StatisticsSerializer.h
+
+// Declares the cStatSerializer class that is used for saving stats into JSON
+
+
+
+
+
+#pragma once
+
+
+
+
+
+struct StatisticsManager;
+namespace Json { class Value; }
+
+
+
+
+
+namespace StatisticsSerializer
+{
+ /* Try to load the player statistics. */
+ void Load(StatisticsManager & Manager, const std::string & WorldPath, std::string && FileName);
+
+ /* Try to save the player statistics. */
+ void Save(const StatisticsManager & Manager, const std::string & WorldPath, std::string && FileName);
+}