mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/4jcraft.git
synced 2026-07-07 20:58:43 +00:00
refactor: expand AUTO_VAR macro
This commit is contained in:
@@ -7,14 +7,14 @@
|
||||
LevelRuleset::LevelRuleset() { m_stringTable = NULL; }
|
||||
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
void LevelRuleset::getChildren(std::vector<GameRuleDefinition*>* children) {
|
||||
CompoundGameRuleDefinition::getChildren(children);
|
||||
for (AUTO_VAR(it, m_areas.begin()); it != m_areas.end(); it++)
|
||||
for (auto it = m_areas.begin(); it != m_areas.end(); it++)
|
||||
children->push_back(*it);
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ const wchar_t* LevelRuleset::getString(const std::wstring& key) {
|
||||
|
||||
AABB* LevelRuleset::getNamedArea(const std::wstring& areaName) {
|
||||
AABB* area = NULL;
|
||||
for (AUTO_VAR(it, m_areas.begin()); it != m_areas.end(); ++it) {
|
||||
for (auto it = m_areas.begin(); it != m_areas.end(); ++it) {
|
||||
if ((*it)->getName().compare(areaName) == 0) {
|
||||
area = (*it)->getArea();
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user