diff --git a/source/common/statistics.cpp b/source/common/statistics.cpp index 27b725d45..46911662d 100644 --- a/source/common/statistics.cpp +++ b/source/common/statistics.cpp @@ -566,9 +566,10 @@ bool ReadStatistics() int numlevels = sjson_child_count(levels); LevelData.Resize(numlevels); + int i = 0; for (auto& lev : LevelData) { - ReadOneLevel(levels, lev); + ReadOneLevel(sjson_find_element(levels, i++), lev); } sjson_destroy_context(ctx); return true;