Remove the unused time_left parameter

The `time_left` was passed to the registered functions but it was never
used.
This commit is contained in:
phosit
2025-10-20 20:28:03 +02:00
parent de841d30e4
commit f257ce8f9c
6 changed files with 32 additions and 33 deletions
+21 -21
View File
@@ -150,55 +150,55 @@ void CMapReader::LoadMap(const VfsPath& pathname, const ScriptContext& cx, JS::
// load map or script settings script
if (settings.isUndefined())
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadScriptSettings();
}, L"CMapReader::LoadScriptSettings", 50);
else
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadRMSettings();
}, L"CMapReader::LoadRMSettings", 50);
// load player settings script (must be done before reading map)
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadPlayerSettings();
}, L"CMapReader::LoadPlayerSettings", 50);
// unpack the data
if (!only_xml)
LDR_Register([this](const double)
LDR_Register([this]
{
return UnpackTerrain();
}, L"CMapReader::UnpackMap", 1200);
// read the corresponding XML file
LDR_Register([this](const double)
LDR_Register([this]
{
return ReadXML();
}, L"CMapReader::ReadXML", 50);
// apply terrain data to the world
LDR_Register([this](const double)
LDR_Register([this]
{
return ApplyTerrainData();
}, L"CMapReader::ApplyTerrainData", 5);
// read entities
LDR_Register([this](const double)
LDR_Register([this]
{
return ReadXMLEntities();
}, L"CMapReader::ReadXMLEntities", 5800);
// apply misc data to the world
LDR_Register([this](const double)
LDR_Register([this]
{
return ApplyData();
}, L"CMapReader::ApplyData", 5);
// load map settings script (must be done after reading map)
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadMapSettings();
}, L"CMapReader::LoadMapSettings", 5);
@@ -232,70 +232,70 @@ void CMapReader::LoadRandomMap(const CStrW& scriptFile, const ScriptContext& cx,
only_xml = false;
// copy random map settings (before entity creation)
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadRMSettings();
}, L"CMapReader::LoadRMSettings", 50);
// load player settings script (must be done before reading map)
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadPlayerSettings();
}, L"CMapReader::LoadPlayerSettings", 50);
// load map generator with random map script
LDR_Register([this, scriptFile](const double)
LDR_Register([this, scriptFile]
{
return StartMapGeneration(scriptFile);
}, L"CMapReader::StartMapGeneration", 1);
LDR_Register([this](const double)
LDR_Register([this]
{
return PollMapGeneration();
}, L"CMapReader::PollMapGeneration", 19999);
// parse RMS results into terrain structure
LDR_Register([this](const double)
LDR_Register([this]
{
return ParseTerrain();
}, L"CMapReader::ParseTerrain", 500);
// parse RMS results into environment settings
LDR_Register([this](const double)
LDR_Register([this]
{
return ParseEnvironment();
}, L"CMapReader::ParseEnvironment", 5);
// parse RMS results into camera settings
LDR_Register([this](const double)
LDR_Register([this]
{
return ParseCamera();
}, L"CMapReader::ParseCamera", 5);
// apply terrain data to the world
LDR_Register([this](const double)
LDR_Register([this]
{
return ApplyTerrainData();
}, L"CMapReader::ApplyTerrainData", 5);
// parse RMS results into entities
LDR_Register([this](const double)
LDR_Register([this]
{
return StartParseEntities();
}, L"CMapReader::StartParseEntities", 10);
LDR_Register([this](const double)
LDR_Register([this]
{
return PollParseEntities();
}, L"CMapReader::PollParseEntities", 1000);
// apply misc data to the world
LDR_Register([this](const double)
LDR_Register([this]
{
return ApplyData();
}, L"CMapReader::ApplyData", 5);
// load map settings script (must be done after reading map)
LDR_Register([this](const double)
LDR_Register([this]
{
return LoadMapSettings();
}, L"CMapReader::LoadMapSettings", 5);