Remove AUTO_VAR macro and _toString function (#592)

This commit is contained in:
void_17
2026-03-06 02:11:18 +07:00
committed by GitHub
parent 7d6658fe5b
commit 55231bb8d3
294 changed files with 5067 additions and 5773 deletions

View File

@@ -11,7 +11,7 @@ LevelRuleset::LevelRuleset()
LevelRuleset::~LevelRuleset()
{
for(AUTO_VAR(it, m_areas.begin()); it != m_areas.end(); ++it)
for (auto it = m_areas.begin(); it != m_areas.end(); ++it)
{
delete *it;
}
@@ -20,8 +20,8 @@ LevelRuleset::~LevelRuleset()
void LevelRuleset::getChildren(vector<GameRuleDefinition *> *children)
{
CompoundGameRuleDefinition::getChildren(children);
for (AUTO_VAR(it, m_areas.begin()); it != m_areas.end(); it++)
children->push_back(*it);
for (const auto& area : m_areas)
children->push_back(area);
}
GameRuleDefinition *LevelRuleset::addChild(ConsoleGameRules::EGameRuleType ruleType)
@@ -58,12 +58,12 @@ LPCWSTR LevelRuleset::getString(const wstring &key)
AABB *LevelRuleset::getNamedArea(const wstring &areaName)
{
AABB *area = NULL;
for(AUTO_VAR(it, m_areas.begin()); it != m_areas.end(); ++it)
AABB *area = nullptr;
for(auto& it : m_areas)
{
if( (*it)->getName().compare(areaName) == 0 )
if( it->getName().compare(areaName) == 0 )
{
area = (*it)->getArea();
area = it->getArea();
break;
}
}