summaryrefslogtreecommitdiffstats
path: root/pokemod/MapWildList.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'pokemod/MapWildList.cpp')
-rw-r--r--pokemod/MapWildList.cpp15
1 files changed, 4 insertions, 11 deletions
diff --git a/pokemod/MapWildList.cpp b/pokemod/MapWildList.cpp
index e9e7b71c..df47e517 100644
--- a/pokemod/MapWildList.cpp
+++ b/pokemod/MapWildList.cpp
@@ -107,9 +107,7 @@ void MapWildList::setControl(const int control)
emit(error(bounds("control")));
return;
}
- m_control = control;
- m_value = INT_MAX;
- emit(changed());
+ CHECK(control);
}
void MapWildList::setValue(const int value)
@@ -127,8 +125,7 @@ void MapWildList::setValue(const int value)
const ItemEffect* effect = item->effect(j);
if ((effect->effect() == ItemEffect::E_Fish) && (effect->value2() == value))
{
- m_value = value;
- emit(changed());
+ CHECK(value);
return;
}
}
@@ -170,8 +167,7 @@ void MapWildList::setScope(const int scope)
const ItemEffect* effect = item->effect(j);
if ((effect->effect() == ItemEffect::E_Scope) && (effect->value2() == scope))
{
- m_scope = scope;
- emit(changed());
+ CHECK(scope);
return;
}
}
@@ -179,10 +175,7 @@ void MapWildList::setScope(const int scope)
emit(error(bounds("value")));
}
else
- {
- m_scope = scope;
- emit(changed());
- }
+ CHECK(scope);
}
int MapWildList::control() const