summaryrefslogtreecommitdiffstats
path: root/pokemod/Map.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'pokemod/Map.cpp')
-rw-r--r--pokemod/Map.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/pokemod/Map.cpp b/pokemod/Map.cpp
index 92cdb98e..d66552e6 100644
--- a/pokemod/Map.cpp
+++ b/pokemod/Map.cpp
@@ -152,19 +152,17 @@ QDomElement Map::save() const
void Map::setName(const QString& name)
{
- m_name = name;
- emit(changed());
+ CHECK(name);
}
-void Map::setFlyWarp(const int warp)
+void Map::setFlyWarp(const int flyWarp)
{
- if ((warp != INT_MAX) && (warpIndex(warp) == INT_MAX))
+ if ((flyWarp != INT_MAX) && (warpIndex(flyWarp) == INT_MAX))
{
- emit(error(bounds("warp")));
+ emit(error(bounds("flyWarp")));
return;
}
- m_flyWarp = warp;
- emit(changed());
+ CHECK(flyWarp);
}
void Map::setType(const int type)
@@ -174,8 +172,7 @@ void Map::setType(const int type)
emit(error(bounds("type")));
return;
}
- m_type = type;
- emit(changed());
+ CHECK(type);
}
QString Map::name() const