Debug: Log number of GRFs at level sl=2 when loading a game

Add helper to get the number of non-static GRFs in a GRF config
This commit is contained in:
Jonathan G Rennison
2024-04-29 20:14:37 +01:00
parent adc7840f01
commit c5cd598217
5 changed files with 17 additions and 9 deletions

View File

@@ -11,6 +11,7 @@
#include "../fios.h"
#include "../load_check.h"
#include "../string_func.h"
#include "../debug.h"
#include "saveload.h"
#include "newgrf_sl.h"
@@ -118,6 +119,7 @@ static void Load_NGRF_common(GRFConfig *&grfconfig)
if (IsSavegameVersionBefore(SLV_101)) c->SetSuitablePalette();
AppendToGRFConfigList(&grfconfig, c);
}
DEBUG(sl, 2, "Loaded %u NewGRFs", GetGRFConfigListNonStaticCount(grfconfig));
}
static void Load_NGRF()