summaryrefslogtreecommitdiffstats
path: root/pokemod/Pokemod.cpp
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2008-01-21 17:13:11 +0000
committerBen Boeckel <MathStuf@gmail.com>2008-01-21 17:13:11 +0000
commita1fff27395d1930820e6c007fdedd8e9dc58f0b3 (patch)
treef61c6b86b4a415fdc2bd0f7d6ca9bfdbfd8e8b64 /pokemod/Pokemod.cpp
parent342fa6879e9fd8a757ebabe0a30370137b8d83a7 (diff)
downloadsigen-a1fff27395d1930820e6c007fdedd8e9dc58f0b3.tar.gz
sigen-a1fff27395d1930820e6c007fdedd8e9dc58f0b3.tar.xz
sigen-a1fff27395d1930820e6c007fdedd8e9dc58f0b3.zip
[FIX] PokeMod namespace removed
[ADD] MoveEffect editing form for PokéModr git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@38 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'pokemod/Pokemod.cpp')
-rw-r--r--pokemod/Pokemod.cpp400
1 files changed, 206 insertions, 194 deletions
diff --git a/pokemod/Pokemod.cpp b/pokemod/Pokemod.cpp
index b59fefe4..ea8f7528 100644
--- a/pokemod/Pokemod.cpp
+++ b/pokemod/Pokemod.cpp
@@ -29,7 +29,7 @@
#include "../general/Ref.h"
#include "Pokemod.h"
-PokeMod::Pokemod::Pokemod(const QString& fname) :
+Pokemod::Pokemod(const QString& fname) :
Object(*this, 0),
valstream(NULL),
title(""),
@@ -45,7 +45,7 @@ PokeMod::Pokemod::Pokemod(const QString& fname) :
load(fname);
}
-bool PokeMod::Pokemod::validate() const
+bool Pokemod::validate() const
{
bool valid = true;
validationMsg(QString("Pokemod \"%1\"").arg(title), V_Msg);
@@ -599,12 +599,12 @@ bool PokeMod::Pokemod::validate() const
return valid;
}
-QString PokeMod::Pokemod::getPath() const
+QString Pokemod::getPath() const
{
return path;
}
-void PokeMod::Pokemod::load(const QString& fname) throw(Exception)
+void Pokemod::load(const QString& fname) throw(Exception)
{
Ini ini(fname);
QStringList fpath = fname.split('\\', QString::SkipEmptyParts).join("/").split('\\', QString::SkipEmptyParts);
@@ -744,7 +744,7 @@ void PokeMod::Pokemod::load(const QString& fname) throw(Exception)
}
}
-void PokeMod::Pokemod::save() const throw(Exception)
+void Pokemod::save() const throw(Exception)
{
Ini ini;
ini.addField("title", title);
@@ -798,34 +798,34 @@ void PokeMod::Pokemod::save() const throw(Exception)
i.next().save();
}
-unsigned PokeMod::Pokemod::maxCompatability(const Pokemod& p) const
+unsigned Pokemod::maxCompatability(const Pokemod& p) const
{
// TODO (Ben #1#): MaxCompatability between two versions
}
-void PokeMod::Pokemod::setTitle(const QString& t)
+void Pokemod::setTitle(const QString& t)
{
title = t;
}
-void PokeMod::Pokemod::setVersion(const QString& v)
+void Pokemod::setVersion(const QString& v)
{
version = v;
}
-void PokeMod::Pokemod::setDescription(const QString& d)
+void Pokemod::setDescription(const QString& d)
{
description = d;
}
-void PokeMod::Pokemod::setStartMap(const unsigned s) throw(BoundsException)
+void Pokemod::setStartMap(const unsigned s) throw(BoundsException)
{
if (getMapIndex(s) == UINT_MAX)
throw(BoundsException("Pokemod", "startMap"));
startMap = s;
}
-void PokeMod::Pokemod::setStartWarp(const unsigned s) throw(BoundsException)
+void Pokemod::setStartWarp(const unsigned s) throw(BoundsException)
{
if (getMapIndex(startMap) == UINT_MAX)
throw(BoundsException("Pokemod", "startMap"));
@@ -834,7 +834,7 @@ void PokeMod::Pokemod::setStartWarp(const unsigned s) throw(BoundsException)
startWarp = s;
}
-void PokeMod::Pokemod::setWalkSkin(const QString& fname) throw(Exception)
+void Pokemod::setWalkSkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/walk.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -843,7 +843,7 @@ void PokeMod::Pokemod::setWalkSkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setBikeSkin(const QString& fname) throw(Exception)
+void Pokemod::setBikeSkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/bike.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -852,7 +852,7 @@ void PokeMod::Pokemod::setBikeSkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setSurfSkin(const QString& fname) throw(Exception)
+void Pokemod::setSurfSkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/surf.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -861,7 +861,7 @@ void PokeMod::Pokemod::setSurfSkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setFlySkin(const QString& fname) throw(Exception)
+void Pokemod::setFlySkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/fly.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -870,7 +870,7 @@ void PokeMod::Pokemod::setFlySkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setFishSkin(const QString& fname) throw(Exception)
+void Pokemod::setFishSkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/fish.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -879,7 +879,7 @@ void PokeMod::Pokemod::setFishSkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setSurfFishSkin(const QString& fname) throw(Exception)
+void Pokemod::setSurfFishSkin(const QString& fname) throw(Exception)
{
QFile file(QString("%1/image/skin/surfFish.png").arg(getPath()));
if (file.exists() && !file.remove())
@@ -888,126 +888,126 @@ void PokeMod::Pokemod::setSurfFishSkin(const QString& fname) throw(Exception)
throw(SaveException("Pokemod", file.fileName()));
}
-void PokeMod::Pokemod::setSuperPCUname(const QString& u)
+void Pokemod::setSuperPCUname(const QString& u)
{
superPCUname = u;
}
-void PokeMod::Pokemod::setSuperPCPasswd(const QString& p)
+void Pokemod::setSuperPCPasswd(const QString& p)
{
superPCPasswd = p;
}
-void PokeMod::Pokemod::setTypeChart(const unsigned att, const unsigned def, const unsigned n, const unsigned d) throw(Exception)
+void Pokemod::setTypeChart(const unsigned att, const unsigned def, const unsigned n, const unsigned d) throw(Exception)
{
typeChart(att, def).set(n, d);
}
-void PokeMod::Pokemod::setTypeChartNum(const unsigned att, const unsigned def, const unsigned n) throw(Exception)
+void Pokemod::setTypeChartNum(const unsigned att, const unsigned def, const unsigned n) throw(Exception)
{
typeChart(att, def).setNum(n);
}
-void PokeMod::Pokemod::setTypeChartDenom(const unsigned att, const unsigned def, const unsigned d) throw(Exception)
+void Pokemod::setTypeChartDenom(const unsigned att, const unsigned def, const unsigned d) throw(Exception)
{
typeChart(att, def).setDenom(d);
}
-void PokeMod::Pokemod::setRules(const Rules& r)
+void Pokemod::setRules(const Rules& r)
{
rules = r;
}
-void PokeMod::Pokemod::setRules(const QString& fname)
+void Pokemod::setRules(const QString& fname)
{
rules.load(fname);
}
-QString PokeMod::Pokemod::getTitle() const
+QString Pokemod::getTitle() const
{
return title;
}
-QString PokeMod::Pokemod::getVersion() const
+QString Pokemod::getVersion() const
{
return version;
}
-QString PokeMod::Pokemod::getDescription() const
+QString Pokemod::getDescription() const
{
return description;
}
-unsigned PokeMod::Pokemod::getStartMap() const
+unsigned Pokemod::getStartMap() const
{
return startMap;
}
-unsigned PokeMod::Pokemod::getStartWarp() const
+unsigned Pokemod::getStartWarp() const
{
return startWarp;
}
-QString PokeMod::Pokemod::getSuperPCUname() const
+QString Pokemod::getSuperPCUname() const
{
return superPCUname;
}
-QString PokeMod::Pokemod::getSuperPCPasswd() const
+QString Pokemod::getSuperPCPasswd() const
{
return superPCPasswd;
}
-const FracMatrix& PokeMod::Pokemod::getTypeChart() const
+const FracMatrix& Pokemod::getTypeChart() const
{
return typeChart;
}
-FracMatrix& PokeMod::Pokemod::getTypeChart()
+FracMatrix& Pokemod::getTypeChart()
{
return typeChart;
}
-Frac PokeMod::Pokemod::getTypeChart(const unsigned att, const unsigned def) const
+Frac Pokemod::getTypeChart(const unsigned att, const unsigned def) const
{
return typeChart(att, def);
}
-const PokeMod::Rules& PokeMod::Pokemod::getRules() const
+const Rules& Pokemod::getRules() const
{
return rules;
}
-PokeMod::Rules& PokeMod::Pokemod::getRules()
+Rules& Pokemod::getRules()
{
return rules;
}
-const PokeMod::Ability& PokeMod::Pokemod::getAbility(const unsigned i) const throw(IndexException)
+const Ability& Pokemod::getAbility(const unsigned i) const throw(IndexException)
{
if (getAbilityCount() <= i)
throw(IndexException("Pokemod"));
return abilities.at(i);
}
-PokeMod::Ability& PokeMod::Pokemod::getAbility(const unsigned i) throw(IndexException)
+Ability& Pokemod::getAbility(const unsigned i) throw(IndexException)
{
if (getAbilityCount() <= i)
throw(IndexException("Pokemod"));
return abilities[i];
}
-const PokeMod::Ability& PokeMod::Pokemod::getAbilityByID(const unsigned i) const throw(IndexException)
+const Ability& Pokemod::getAbilityByID(const unsigned i) const throw(IndexException)
{
return getAbility(getAbilityIndex(i));
}
-PokeMod::Ability& PokeMod::Pokemod::getAbilityByID(const unsigned i) throw(IndexException)
+Ability& Pokemod::getAbilityByID(const unsigned i) throw(IndexException)
{
return getAbility(getAbilityIndex(i));
}
-unsigned PokeMod::Pokemod::getAbilityIndex(const unsigned _id) const
+unsigned Pokemod::getAbilityIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getAbilityCount(); ++i)
{
@@ -1017,61 +1017,61 @@ unsigned PokeMod::Pokemod::getAbilityIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getAbilityCount() const
+unsigned Pokemod::getAbilityCount() const
{
return abilities.size();
}
-PokeMod::Ability& PokeMod::Pokemod::newAbility()
+Ability& Pokemod::newAbility()
{
abilities.append(Ability(*this, getNewAbilityId()));
return abilities[getAbilityCount() - 1];
}
-PokeMod::Ability& PokeMod::Pokemod::newAbility(const QString& fname)
+Ability& Pokemod::newAbility(const QString& fname)
{
abilities.append(Ability(*this, fname, getNewAbilityId()));
return abilities[getAbilityCount() - 1];
}
-PokeMod::Ability& PokeMod::Pokemod::newAbility(const Ability& a)
+Ability& Pokemod::newAbility(const Ability& a)
{
abilities.append(Ability(*this, a, getNewAbilityId()));
return abilities[getAbilityCount() - 1];
}
-void PokeMod::Pokemod::deleteAbility(const unsigned i) throw(IndexException)
+void Pokemod::deleteAbility(const unsigned i) throw(IndexException)
{
if (getAbilityCount() <= i)
throw(IndexException("Pokemod"));
abilities.removeAt(i);
}
-const PokeMod::Author& PokeMod::Pokemod::getAuthor(const unsigned i) const throw(IndexException)
+const Author& Pokemod::getAuthor(const unsigned i) const throw(IndexException)
{
if (getAuthorCount() <= i)
throw(IndexException("Pokemod"));
return authors.at(i);
}
-PokeMod::Author& PokeMod::Pokemod::getAuthor(const unsigned i) throw(IndexException)
+Author& Pokemod::getAuthor(const unsigned i) throw(IndexException)
{
if (getAuthorCount() <= i)
throw(IndexException("Pokemod"));
return authors[i];
}
-const PokeMod::Author& PokeMod::Pokemod::getAuthorByID(const unsigned i) const throw(IndexException)
+const Author& Pokemod::getAuthorByID(const unsigned i) const throw(IndexException)
{
return getAuthor(getAuthorIndex(i));
}
-PokeMod::Author& PokeMod::Pokemod::getAuthorByID(const unsigned i) throw(IndexException)
+Author& Pokemod::getAuthorByID(const unsigned i) throw(IndexException)
{
return getAuthor(getAuthorIndex(i));
}
-unsigned PokeMod::Pokemod::getAuthorIndex(const unsigned _id) const
+unsigned Pokemod::getAuthorIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getAuthorCount(); ++i)
{
@@ -1081,49 +1081,61 @@ unsigned PokeMod::Pokemod::getAuthorIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getAuthorCount() const
+unsigned Pokemod::getAuthorCount() const
{
return authors.size();
}
-PokeMod::Author& PokeMod::Pokemod::newAuthor()
+Author& Pokemod::newAuthor()
{
authors.append(Author(*this, getNewAuthorId()));
return authors[getAuthorCount() + 1];
}
-void PokeMod::Pokemod::deleteAuthor(const unsigned i) throw(IndexException)
+Author& Pokemod::newAuthor(const QString& fname)
+{
+ authors.append(Author(*this, fname, getNewAuthorId()));
+ return authors[getAuthorCount() + 1];
+}
+
+Author& Pokemod::newAuthor(const Author& a)
+{
+ authors.append(Author(*this, a, getNewAuthorId()));
+ return authors[getAuthorCount() + 1];
+}
+
+void Pokemod::deleteAuthor(const unsigned i) throw(IndexException)
{
if (getAuthorCount() <= i)
throw(IndexException("Pokemod"));
authors.removeAt(i);
}
-const PokeMod::Badge& PokeMod::Pokemod::getBadge(const unsigned i) const throw(IndexException)
+const Badge& Pokemod::getBadge(const unsigned i) const throw(IndexException)
{
if (i < getBadgeCount())
throw(IndexException("Pokemod"));
return badges.at(i);
}
-PokeMod::Badge& PokeMod::Pokemod::getBadge(const unsigned i) throw(IndexException)
+Badge& Pokemod::getBadge(const unsigned i) throw(IndexException)
{
if (i < getBadgeCount())
throw(IndexException("Pokemod"));
return badges[i];
}
-const PokeMod::Badge& PokeMod::Pokemod::getBadgeByID(const unsigned i) const throw(IndexException)
+const Badge& Pokemod::getBadgeByID(const unsigned i) const throw(IndexException)
{
return getBadge(getBadgeIndex(i));
}
-PokeMod::Badge& PokeMod::Pokemod::getBadgeByID(const unsigned i) throw(IndexException)
+Badge& Pokemod::getBadgeByID(const unsigned i) throw(IndexException)
{
return getBadge(getBadgeIndex(i));
}
-unsigned PokeMod::Pokemod::getBadgeIndex(const unsigned _id) const
+unsigned Pokemod::getBadgeIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getBadgeCount(); ++i)
{
@@ -1133,61 +1145,61 @@ unsigned PokeMod::Pokemod::getBadgeIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getBadgeCount() const
+unsigned Pokemod::getBadgeCount() const
{
return badges.size();
}
-PokeMod::Badge& PokeMod::Pokemod::newBadge()
+Badge& Pokemod::newBadge()
{
badges.append(Badge(*this, getNewBadgeId()));
return badges[getBadgeCount() - 1];
}
-PokeMod::Badge& PokeMod::Pokemod::newBadge(const QString& fname)
+Badge& Pokemod::newBadge(const QString& fname)
{
badges.append(Badge(*this, fname, getNewBadgeId()));
return badges[getBadgeCount() - 1];
}
-PokeMod::Badge& PokeMod::Pokemod::newBadge(const Badge& b)
+Badge& Pokemod::newBadge(const Badge& b)
{
badges.append(Badge(*this, b, getNewBadgeId()));
return badges[getBadgeCount() - 1];
}
-void PokeMod::Pokemod::deleteBadge(const unsigned i) throw(IndexException)
+void Pokemod::deleteBadge(const unsigned i) throw(IndexException)
{
if (getBadgeCount() <= i)
throw(IndexException("Pokemod"));
badges.removeAt(i);
}
-const PokeMod::CoinList& PokeMod::Pokemod::getCoinList(const unsigned i) const throw(IndexException)
+const CoinList& Pokemod::getCoinList(const unsigned i) const throw(IndexException)
{
if (getCoinListCount() <= i)
throw(IndexException("Pokemod"));
return coinLists.at(i);
}
-PokeMod::CoinList& PokeMod::Pokemod::getCoinList(const unsigned i) throw(IndexException)
+CoinList& Pokemod::getCoinList(const unsigned i) throw(IndexException)
{
if (getCoinListCount() <= i)
throw(IndexException("Pokemod"));
return coinLists[i];
}
-const PokeMod::CoinList& PokeMod::Pokemod::getCoinListByID(const unsigned i) const throw(IndexException)
+const CoinList& Pokemod::getCoinListByID(const unsigned i) const throw(IndexException)
{
return getCoinList(getCoinListIndex(i));
}
-PokeMod::CoinList& PokeMod::Pokemod::getCoinListByID(const unsigned i) throw(IndexException)
+CoinList& Pokemod::getCoinListByID(const unsigned i) throw(IndexException)
{
return getCoinList(getCoinListIndex(i));
}
-unsigned PokeMod::Pokemod::getCoinListIndex(const unsigned _id) const
+unsigned Pokemod::getCoinListIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getCoinListCount(); ++i)
{
@@ -1197,61 +1209,61 @@ unsigned PokeMod::Pokemod::getCoinListIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getCoinListCount() const
+unsigned Pokemod::getCoinListCount() const
{
return coinLists.size();
}
-PokeMod::CoinList& PokeMod::Pokemod::newCoinList()
+CoinList& Pokemod::newCoinList()
{
coinLists.append(CoinList(*this, getNewCoinListId()));
return coinLists[getCoinListCount() - 1];
}
-PokeMod::CoinList& PokeMod::Pokemod::newCoinList(const QString& fname)
+CoinList& Pokemod::newCoinList(const QString& fname)
{
coinLists.append(CoinList(*this, fname, getNewCoinListId()));
return coinLists[getCoinListCount() - 1];
}
-PokeMod::CoinList& PokeMod::Pokemod::newCoinList(const CoinList& c)
+CoinList& Pokemod::newCoinList(const CoinList& c)
{
coinLists.append(CoinList(*this, c, getNewCoinListId()));
return coinLists[getCoinListCount() - 1];
}
-void PokeMod::Pokemod::deleteCoinList(const unsigned i) throw(IndexException)
+void Pokemod::deleteCoinList(const unsigned i) throw(IndexException)
{
if (getCoinListCount() <= i)
throw(IndexException("Pokemod"));
coinLists.removeAt(i);
}
-const PokeMod::Dialog& PokeMod::Pokemod::getDialog(const unsigned i) const throw(IndexException)
+const Dialog& Pokemod::getDialog(const unsigned i) const throw(IndexException)
{
if (getDialogCount() <= i)
throw(IndexException("Pokemod"));
return dialogs.at(i);
}
-PokeMod::Dialog& PokeMod::Pokemod::getDialog(const unsigned i) throw(IndexException)
+Dialog& Pokemod::getDialog(const unsigned i) throw(IndexException)
{
if (getDialogCount() <= i)
throw(IndexException("Pokemod"));
return dialogs[i];
}
-const PokeMod::Dialog& PokeMod::Pokemod::getDialogByID(const unsigned i) const throw(IndexException)
+const Dialog& Pokemod::getDialogByID(const unsigned i) const throw(IndexException)
{
return getDialog(getDialogIndex(i));
}
-PokeMod::Dialog& PokeMod::Pokemod::getDialogByID(const unsigned i) throw(IndexException)
+Dialog& Pokemod::getDialogByID(const unsigned i) throw(IndexException)
{
return getDialog(getDialogIndex(i));
}
-unsigned PokeMod::Pokemod::getDialogIndex(const unsigned _id) const
+unsigned Pokemod::getDialogIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getDialogCount(); ++i)
{
@@ -1261,61 +1273,61 @@ unsigned PokeMod::Pokemod::getDialogIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getDialogCount() const
+unsigned Pokemod::getDialogCount() const
{
return dialogs.size();
}
-PokeMod::Dialog& PokeMod::Pokemod::newDialog()
+Dialog& Pokemod::newDialog()
{
dialogs.append(Dialog(*this, getNewDialogId()));
return dialogs[getDialogCount() - 1];
}
-PokeMod::Dialog& PokeMod::Pokemod::newDialog(const QString& fname)
+Dialog& Pokemod::newDialog(const QString& fname)
{
dialogs.append(Dialog(*this, fname, getNewDialogId()));
return dialogs[getDialogCount() - 1];
}
-PokeMod::Dialog& PokeMod::Pokemod::newDialog(const Dialog& d)
+Dialog& Pokemod::newDialog(const Dialog& d)
{
dialogs.append(Dialog(*this, d, getNewDialogId()));
return dialogs[getDialogCount() - 1];
}
-void PokeMod::Pokemod::deleteDialog(const unsigned i) throw(IndexException)
+void Pokemod::deleteDialog(const unsigned i) throw(IndexException)
{
if (getDialogCount() <= i)
throw(IndexException("Pokemod"));
dialogs.removeAt(i);
}
-const PokeMod::EggGroup& PokeMod::Pokemod::getEggGroup(const unsigned i) const throw(IndexException)
+const EggGroup& Pokemod::getEggGroup(const unsigned i) const throw(IndexException)
{
if (getEggGroupCount() <= i)
throw(IndexException("Pokemod"));
return eggGroups.at(i);
}
-PokeMod::EggGroup& PokeMod::Pokemod::getEggGroup(const unsigned i) throw(IndexException)
+EggGroup& Pokemod::getEggGroup(const unsigned i) throw(IndexException)
{
if (getEggGroupCount() <= i)
throw(IndexException("Pokemod"));
return eggGroups[i];
}
-const PokeMod::EggGroup& PokeMod::Pokemod::getEggGroupByID(const unsigned i) const throw(IndexException)
+const EggGroup& Pokemod::getEggGroupByID(const unsigned i) const throw(IndexException)
{
return getEggGroup(getEggGroupIndex(i));
}
-PokeMod::EggGroup& PokeMod::Pokemod::getEggGroupByID(const unsigned i) throw(IndexException)
+EggGroup& Pokemod::getEggGroupByID(const unsigned i) throw(IndexException)
{
return getEggGroup(getEggGroupIndex(i));
}
-unsigned PokeMod::Pokemod::getEggGroupIndex(const unsigned _id) const
+unsigned Pokemod::getEggGroupIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getEggGroupCount(); ++i)
{
@@ -1325,61 +1337,61 @@ unsigned PokeMod::Pokemod::getEggGroupIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getEggGroupCount() const
+unsigned Pokemod::getEggGroupCount() const
{
return eggGroups.size();
}
-PokeMod::EggGroup& PokeMod::Pokemod::newEggGroup()
+EggGroup& Pokemod::newEggGroup()
{
eggGroups.append(EggGroup(*this, getNewEggGroupId()));
return eggGroups[getEggGroupCount() - 1];
}
-PokeMod::EggGroup& PokeMod::Pokemod::newEggGroup(const QString& fname)
+EggGroup& Pokemod::newEggGroup(const QString& fname)
{
eggGroups.append(EggGroup(*this, fname, getNewEggGroupId()));
return eggGroups[getEggGroupCount() - 1];
}
-PokeMod::EggGroup& PokeMod::Pokemod::newEggGroup(const EggGroup& e)
+EggGroup& Pokemod::newEggGroup(const EggGroup& e)
{
eggGroups.append(EggGroup(*this, e, getNewEggGroupId()));
return eggGroups[getEggGroupCount() - 1];
}
-void PokeMod::Pokemod::deleteEggGroup(const unsigned i) throw(IndexException)
+void Pokemod::deleteEggGroup(const unsigned i) throw(IndexException)
{
if (getEggGroupCount() <= i)
throw(IndexException("Pokemod"));
eggGroups.removeAt(i);
}
-const PokeMod::Item& PokeMod::Pokemod::getItem(const unsigned i) const throw(IndexException)
+const Item& Pokemod::getItem(const unsigned i) const throw(IndexException)
{
if (getItemCount() <= i)
throw(IndexException("Pokemod"));
return items.at(i);
}
-PokeMod::Item& PokeMod::Pokemod::getItem(const unsigned i) throw(IndexException)
+Item& Pokemod::getItem(const unsigned i) throw(IndexException)
{
if (getItemCount() <= i)
throw(IndexException("Pokemod"));
return items[i];
}
-const PokeMod::Item& PokeMod::Pokemod::getItemByID(const unsigned i) const throw(IndexException)
+const Item& Pokemod::getItemByID(const unsigned i) const throw(IndexException)
{
return getItem(getItemIndex(i));
}
-PokeMod::Item& PokeMod::Pokemod::getItemByID(const unsigned i) throw(IndexException)
+Item& Pokemod::getItemByID(const unsigned i) throw(IndexException)
{
return getItem(getItemIndex(i));
}
-unsigned PokeMod::Pokemod::getItemIndex(const unsigned _id) const
+unsigned Pokemod::getItemIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getItemCount(); ++i)
{
@@ -1389,61 +1401,61 @@ unsigned PokeMod::Pokemod::getItemIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getItemCount() const
+unsigned Pokemod::getItemCount() const
{
return items.size();
}
-PokeMod::Item& PokeMod::Pokemod::newItem()
+Item& Pokemod::newItem()
{
items.append(Item(*this, getNewItemId()));
return items[getItemCount() - 1];
}
-PokeMod::Item& PokeMod::Pokemod::newItem(const QString& fname)
+Item& Pokemod::newItem(const QString& fname)
{
items.append(Item(*this, fname, getNewItemId()));
return items[getItemCount() - 1];
}
-PokeMod::Item& PokeMod::Pokemod::newItem(const Item& i)
+Item& Pokemod::newItem(const Item& i)
{
items.append(Item(*this, i, getNewItemId()));
return items[getItemCount() - 1];
}
-void PokeMod::Pokemod::deleteItem(const unsigned i) throw(IndexException)
+void Pokemod::deleteItem(const unsigned i) throw(IndexException)
{
if (getItemCount() <= i)
throw(IndexException("Pokemod"));
items.removeAt(i);
}
-const PokeMod::ItemType& PokeMod::Pokemod::getItemType(const unsigned i) const throw(IndexException)
+const ItemType& Pokemod::getItemType(const unsigned i) const throw(IndexException)
{
if (getItemTypeCount() <= i)
throw(IndexException("Pokemod"));
return itemTypes.at(i);
}
-PokeMod::ItemType& PokeMod::Pokemod::getItemType(const unsigned i) throw(IndexException)
+ItemType& Pokemod::getItemType(const unsigned i) throw(IndexException)
{
if (getItemTypeCount() <= i)
throw(IndexException("Pokemod"));
return itemTypes[i];
}
-const PokeMod::ItemType& PokeMod::Pokemod::getItemTypeByID(const unsigned i) const throw(IndexException)
+const ItemType& Pokemod::getItemTypeByID(const unsigned i) const throw(IndexException)
{
return getItemType(getItemTypeIndex(i));
}
-PokeMod::ItemType& PokeMod::Pokemod::getItemTypeByID(const unsigned i) throw(IndexException)
+ItemType& Pokemod::getItemTypeByID(const unsigned i) throw(IndexException)
{
return getItemType(getItemTypeIndex(i));
}
-unsigned PokeMod::Pokemod::getItemTypeIndex(const unsigned _id) const
+unsigned Pokemod::getItemTypeIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getItemTypeCount(); ++i)
{
@@ -1453,61 +1465,61 @@ unsigned PokeMod::Pokemod::getItemTypeIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getItemTypeCount() const
+unsigned Pokemod::getItemTypeCount() const
{
return itemTypes.size();
}
-PokeMod::ItemType& PokeMod::Pokemod::newItemType()
+ItemType& Pokemod::newItemType()
{
itemTypes.append(ItemType(*this, getNewItemTypeId()));
return itemTypes[getItemTypeCount() - 1];
}
-PokeMod::ItemType& PokeMod::Pokemod::newItemType(const QString& fname)
+ItemType& Pokemod::newItemType(const QString& fname)
{
itemTypes.append(ItemType(*this, fname, getNewItemTypeId()));
return itemTypes[getItemTypeCount() - 1];
}
-PokeMod::ItemType& PokeMod::Pokemod::newItemType(const ItemType& i)
+ItemType& Pokemod::newItemType(const ItemType& i)
{
itemTypes.append(ItemType(*this, i, getNewItemTypeId()));
return itemTypes[getItemTypeCount() - 1];
}
-void PokeMod::Pokemod::deleteItemType(const unsigned i) throw(IndexException)
+void Pokemod::deleteItemType(const unsigned i) throw(IndexException)
{
if (getItemTypeCount() <= i)
throw(IndexException("Pokemod"));
itemTypes.removeAt(i);
}
-const PokeMod::Map& PokeMod::Pokemod::getMap(const unsigned i) const throw(IndexException)
+const Map& Pokemod::getMap(const unsigned i) const throw(IndexException)
{
if (getMapCount() <= i)
throw(IndexException("Pokemod"));
return maps.at(i);
}
-PokeMod::Map& PokeMod::Pokemod::getMap(const unsigned i) throw(IndexException)
+Map& Pokemod::getMap(const unsigned i) throw(IndexException)
{
if (getMapCount() <= i)
throw(IndexException("Pokemod"));
return maps[i];
}
-const PokeMod::Map& PokeMod::Pokemod::getMapByID(const unsigned i) const throw(IndexException)
+const Map& Pokemod::getMapByID(const unsigned i) const throw(IndexException)
{
return getMap(getMapIndex(i));
}
-PokeMod::Map& PokeMod::Pokemod::getMapByID(const unsigned i) throw(IndexException)
+Map& Pokemod::getMapByID(const unsigned i) throw(IndexException)
{
return getMap(getMapIndex(i));
}
-unsigned PokeMod::Pokemod::getMapIndex(const unsigned _id) const
+unsigned Pokemod::getMapIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getMapCount(); ++i)
{
@@ -1517,61 +1529,61 @@ unsigned PokeMod::Pokemod::getMapIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getMapCount() const
+unsigned Pokemod::getMapCount() const
{
return maps.size();
}
-PokeMod::Map& PokeMod::Pokemod::newMap()
+Map& Pokemod::newMap()
{
maps.append(Map(*this, getNewMapId()));
return maps[getMapCount() - 1];
}
-PokeMod::Map& PokeMod::Pokemod::newMap(const QString& fname)
+Map& Pokemod::newMap(const QString& fname)
{
maps.append(Map(*this, fname, getNewMapId()));
return maps[getMapCount() - 1];
}
-PokeMod::Map& PokeMod::Pokemod::newMap(const Map& m)
+Map& Pokemod::newMap(const Map& m)
{
maps.append(Map(*this, m, getNewMapId()));
return maps[getMapCount() - 1];
}
-void PokeMod::Pokemod::deleteMap(const unsigned i) throw(IndexException)
+void Pokemod::deleteMap(const unsigned i) throw(IndexException)
{
if (getMapCount() <= i)
throw(IndexException("Pokemod"));
maps.removeAt(i);
}
-const PokeMod::Move& PokeMod::Pokemod::getMove(const unsigned i) const throw(IndexException)
+const Move& Pokemod::getMove(const unsigned i) const throw(IndexException)
{
if (getMoveCount() <= i)
throw(IndexException("Pokemod"));
return moves.at(i);
}
-PokeMod::Move& PokeMod::Pokemod::getMove(const unsigned i) throw(IndexException)
+Move& Pokemod::getMove(const unsigned i) throw(IndexException)
{
if (getMoveCount() <= i)
throw(IndexException("Pokemod"));
return moves[i];
}
-const PokeMod::Move& PokeMod::Pokemod::getMoveByID(const unsigned i) const throw(IndexException)
+const Move& Pokemod::getMoveByID(const unsigned i) const throw(IndexException)
{
return getMove(getMoveIndex(i));
}
-PokeMod::Move& PokeMod::Pokemod::getMoveByID(const unsigned i) throw(IndexException)
+Move& Pokemod::getMoveByID(const unsigned i) throw(IndexException)
{
return getMove(getMoveIndex(i));
}
-unsigned PokeMod::Pokemod::getMoveIndex(const unsigned _id) const
+unsigned Pokemod::getMoveIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getMoveCount(); ++i)
{
@@ -1581,61 +1593,61 @@ unsigned PokeMod::Pokemod::getMoveIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getMoveCount() const
+unsigned Pokemod::getMoveCount() const
{
return moves.size();
}
-PokeMod::Move& PokeMod::Pokemod::newMove()
+Move& Pokemod::newMove()
{
moves.append(Move(*this, getNewMoveId()));
return moves[getMoveCount() - 1];
}
-PokeMod::Move& PokeMod::Pokemod::newMove(const QString& fname)
+Move& Pokemod::newMove(const QString& fname)
{
moves.append(Move(*this, fname, getNewMoveId()));
return moves[getMoveCount() - 1];
}
-PokeMod::Move& PokeMod::Pokemod::newMove(const Move& m)
+Move& Pokemod::newMove(const Move& m)
{
moves.append(Move(*this, m, getNewMoveId()));
return moves[getMoveCount() - 1];
}
-void PokeMod::Pokemod::deleteMove(const unsigned i) throw(IndexException)
+void Pokemod::deleteMove(const unsigned i) throw(IndexException)
{
if (getMoveCount() <= i)
throw(IndexException("Pokemod"));
moves.removeAt(i);
}
-const PokeMod::Nature& PokeMod::Pokemod::getNature(const unsigned i) const throw(IndexException)
+const Nature& Pokemod::getNature(const unsigned i) const throw(IndexException)
{
if (getNatureCount() <= i)
throw(IndexException("Pokemod"));
return natures.at(i);
}
-PokeMod::Nature& PokeMod::Pokemod::getNature(const unsigned i) throw(IndexException)
+Nature& Pokemod::getNature(const unsigned i) throw(IndexException)
{
if (getNatureCount() <= i)
throw(IndexException("Pokemod"));
return natures[i];
}
-const PokeMod::Nature& PokeMod::Pokemod::getNatureByID(const unsigned i) const throw(IndexException)
+const Nature& Pokemod::getNatureByID(const unsigned i) const throw(IndexException)
{
return getNature(getNatureIndex(i));
}
-PokeMod::Nature& PokeMod::Pokemod::getNatureByID(const unsigned i) throw(IndexException)
+Nature& Pokemod::getNatureByID(const unsigned i) throw(IndexException)
{
return getNature(getNatureIndex(i));
}
-unsigned PokeMod::Pokemod::getNatureIndex(const unsigned _id) const
+unsigned Pokemod::getNatureIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getNatureCount(); ++i)
{
@@ -1645,61 +1657,61 @@ unsigned PokeMod::Pokemod::getNatureIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getNatureCount() const
+unsigned Pokemod::getNatureCount() const
{
return natures.size();
}
-PokeMod::Nature& PokeMod::Pokemod::newNature()
+Nature& Pokemod::newNature()
{
natures.append(Nature(*this, getNewNatureId()));
return natures[getNatureCount() - 1];
}
-PokeMod::Nature& PokeMod::Pokemod::newNature(const QString& fname)
+Nature& Pokemod::newNature(const QString& fname)
{
natures.append(Nature(*this, fname, getNewNatureId()));
return natures[getNatureCount() - 1];
}
-PokeMod::Nature& PokeMod::Pokemod::newNature(const Nature& n)
+Nature& Pokemod::newNature(const Nature& n)
{
natures.append(Nature(*this, n, getNewNatureId()));
return natures[getNatureCount() - 1];
}
-void PokeMod::Pokemod::deleteNature(const unsigned i) throw(IndexException)
+void Pokemod::deleteNature(const unsigned i) throw(IndexException)
{
if (getNatureCount() <= i)
throw(IndexException("Pokemod"));
natures.removeAt(i);
}
-const PokeMod::Species& PokeMod::Pokemod::getSpecies(const unsigned i) const throw(IndexException)
+const Species& Pokemod::getSpecies(const unsigned i) const throw(IndexException)
{
if (getSpeciesCount() <= i)
throw(IndexException("Pokemod"));
return species.at(i);
}
-PokeMod::Species& PokeMod::Pokemod::getSpecies(const unsigned i) throw(IndexException)
+Species& Pokemod::getSpecies(const unsigned i) throw(IndexException)
{
if (getSpeciesCount() <= i)
throw(IndexException("Pokemod"));
return species[i];
}
-const PokeMod::Species& PokeMod::Pokemod::getSpeciesByID(const unsigned i) const throw(IndexException)
+const Species& Pokemod::getSpeciesByID(const unsigned i) const throw(IndexException)
{
return getSpecies(getSpeciesIndex(i));
}
-PokeMod::Species& PokeMod::Pokemod::getSpeciesByID(const unsigned i) throw(IndexException)
+Species& Pokemod::getSpeciesByID(const unsigned i) throw(IndexException)
{
return getSpecies(getSpeciesIndex(i));
}
-unsigned PokeMod::Pokemod::getSpeciesIndex(const unsigned _id) const
+unsigned Pokemod::getSpeciesIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getSpeciesCount(); ++i)
{
@@ -1709,61 +1721,61 @@ unsigned PokeMod::Pokemod::getSpeciesIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getSpeciesCount() const
+unsigned Pokemod::getSpeciesCount() const
{
return species.size();
}
-PokeMod::Species& PokeMod::Pokemod::newSpecies()
+Species& Pokemod::newSpecies()
{
species.append(Species(*this, getNewSpeciesId()));
return species[getSpeciesCount() - 1];
}
-PokeMod::Species& PokeMod::Pokemod::newSpecies(const QString& fname)
+Species& Pokemod::newSpecies(const QString& fname)
{
species.append(Species(*this, fname, getNewSpeciesId()));
return species[getSpeciesCount() - 1];
}
-PokeMod::Species& PokeMod::Pokemod::newSpecies(const Species& s)
+Species& Pokemod::newSpecies(const Species& s)
{
species.append(Species(*this, s, getNewSpeciesId()));
return species[getSpeciesCount() - 1];
}
-void PokeMod::Pokemod::deleteSpecies(const unsigned i) throw(IndexException)
+void Pokemod::deleteSpecies(const unsigned i) throw(IndexException)
{
if (getSpeciesCount() <= i)
throw(IndexException("Pokemod"));
species.removeAt(i);
}
-const PokeMod::Store& PokeMod::Pokemod::getStore(const unsigned i) const throw(IndexException)
+const Store& Pokemod::getStore(const unsigned i) const throw(IndexException)
{
if (getStoreCount() <= i)
throw(IndexException("Pokemod"));
return stores.at(i);
}
-PokeMod::Store& PokeMod::Pokemod::getStore(const unsigned i) throw(IndexException)
+Store& Pokemod::getStore(const unsigned i) throw(IndexException)
{
if (getStoreCount() <= i)
throw(IndexException("Pokemod"));
return stores[i];
}
-const PokeMod::Store& PokeMod::Pokemod::getStoreByID(const unsigned i) const throw(IndexException)
+const Store& Pokemod::getStoreByID(const unsigned i) const throw(IndexException)
{
return getStore(getStoreIndex(i));
}
-PokeMod::Store& PokeMod::Pokemod::getStoreByID(const unsigned i) throw(IndexException)
+Store& Pokemod::getStoreByID(const unsigned i) throw(IndexException)
{
return getStore(getStoreIndex(i));
}
-unsigned PokeMod::Pokemod::getStoreIndex(const unsigned _id) const
+unsigned Pokemod::getStoreIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getStoreCount(); ++i)
{
@@ -1773,61 +1785,61 @@ unsigned PokeMod::Pokemod::getStoreIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getStoreCount() const
+unsigned Pokemod::getStoreCount() const
{
return stores.size();
}
-PokeMod::Store& PokeMod::Pokemod::newStore()
+Store& Pokemod::newStore()
{
stores.append(Store(*this, getNewStoreId()));
return stores[getStoreCount() - 1];
}
-PokeMod::Store& PokeMod::Pokemod::newStore(const QString& fname)
+Store& Pokemod::newStore(const QString& fname)
{
stores.append(Store(*this, fname, getNewStoreId()));
return stores[getStoreCount() - 1];
}
-PokeMod::Store& PokeMod::Pokemod::newStore(const Store& s)
+Store& Pokemod::newStore(const Store& s)
{
stores.append(Store(*this, s, getNewStoreId()));
return stores[getStoreCount() - 1];
}
-void PokeMod::Pokemod::deleteStore(const unsigned i) throw(IndexException)
+void Pokemod::deleteStore(const unsigned i) throw(IndexException)
{
if (getStoreCount() <= i)
throw(IndexException("Pokemod"));
stores.removeAt(i);
}
-const PokeMod::Tile& PokeMod::Pokemod::getTile(const unsigned i) const throw(IndexException)
+const Tile& Pokemod::getTile(const unsigned i) const throw(IndexException)
{
if (getTileCount() <= i)
throw(IndexException("Pokemod"));
return tiles.at(i);
}
-PokeMod::Tile& PokeMod::Pokemod::getTile(const unsigned i) throw(IndexException)
+Tile& Pokemod::getTile(const unsigned i) throw(IndexException)
{
if (getTileCount() <= i)
throw(IndexException("Pokemod"));
return tiles[i];
}
-const PokeMod::Tile& PokeMod::Pokemod::getTileByID(const unsigned i) const throw(IndexException)
+const Tile& Pokemod::getTileByID(const unsigned i) const throw(IndexException)
{
return getTile(getTileIndex(i));
}
-PokeMod::Tile& PokeMod::Pokemod::getTileByID(const unsigned i) throw(IndexException)
+Tile& Pokemod::getTileByID(const unsigned i) throw(IndexException)
{
return getTile(getTileIndex(i));
}
-unsigned PokeMod::Pokemod::getTileIndex(const unsigned _id) const
+unsigned Pokemod::getTileIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getTileCount(); ++i)
{
@@ -1837,61 +1849,61 @@ unsigned PokeMod::Pokemod::getTileIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getTileCount() const
+unsigned Pokemod::getTileCount() const
{
return tiles.size();
}
-PokeMod::Tile& PokeMod::Pokemod::newTile()
+Tile& Pokemod::newTile()
{
tiles.append(Tile(*this, getNewTileId()));
return tiles[getTileCount() - 1];
}
-PokeMod::Tile& PokeMod::Pokemod::newTile(const QString& fname)
+Tile& Pokemod::newTile(const QString& fname)
{
tiles.append(Tile(*this, fname, getNewTileId()));
return tiles[getTileCount() - 1];
}
-PokeMod::Tile& PokeMod::Pokemod::newTile(const Tile& t)
+Tile& Pokemod::newTile(const Tile& t)
{
tiles.append(Tile(*this, t, getNewTileId()));
return tiles[getTileCount() - 1];
}
-void PokeMod::Pokemod::deleteTile(const unsigned i) throw(IndexException)
+void Pokemod::deleteTile(const unsigned i) throw(IndexException)
{
if (getTileCount() <= i)
throw(IndexException("Pokemod"));
tiles.removeAt(i);
}
-const PokeMod::Time& PokeMod::Pokemod::getTime(const unsigned i) const throw(IndexException)
+const Time& Pokemod::getTime(const unsigned i) const throw(IndexException)
{
if (getTimeCount() <= i)
throw(IndexException("Pokemod"));
return times.at(i);
}
-PokeMod::Time& PokeMod::Pokemod::getTime(const unsigned i) throw(IndexException)
+Time& Pokemod::getTime(const unsigned i) throw(IndexException)
{
if (getTimeCount() <= i)
throw(IndexException("Pokemod"));
return times[i];
}
-const PokeMod::Time& PokeMod::Pokemod::getTimeByID(const unsigned i) const throw(IndexException)
+const Time& Pokemod::getTimeByID(const unsigned i) const throw(IndexException)
{
return getTime(getTimeIndex(i));
}
-PokeMod::Time& PokeMod::Pokemod::getTimeByID(const unsigned i) throw(IndexException)
+Time& Pokemod::getTimeByID(const unsigned i) throw(IndexException)
{
return getTime(getTimeIndex(i));
}
-unsigned PokeMod::Pokemod::getTimeIndex(const unsigned _id) const
+unsigned Pokemod::getTimeIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getTimeCount(); ++i)
{
@@ -1901,61 +1913,61 @@ unsigned PokeMod::Pokemod::getTimeIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getTimeCount() const
+unsigned Pokemod::getTimeCount() const
{
return times.size();
}
-PokeMod::Time& PokeMod::Pokemod::newTime()
+Time& Pokemod::newTime()
{
times.append(Time(*this, getNewTimeId()));
return times[getTimeCount() - 1];
}
-PokeMod::Time& PokeMod::Pokemod::newTime(const QString& fname)
+Time& Pokemod::newTime(const QString& fname)
{
times.append(Time(*this, fname, getNewTimeId()));
return times[getTimeCount() - 1];
}
-PokeMod::Time& PokeMod::Pokemod::newTime(const Time& t)
+Time& Pokemod::newTime(const Time& t)
{
times.append(Time(*this, t, getNewTimeId()));
return times[getTimeCount() - 1];
}
-void PokeMod::Pokemod::deleteTime(const unsigned i) throw(IndexException)
+void Pokemod::deleteTime(const unsigned i) throw(IndexException)
{
if (getTimeCount() <= i)
throw(IndexException("Pokemod"));
times.removeAt(i);
}
-const PokeMod::Type& PokeMod::Pokemod::getType(const unsigned i) const throw(IndexException)
+const Type& Pokemod::getType(const unsigned i) const throw(IndexException)
{
if (getTypeCount() <= i)
throw(IndexException("Pokemod"));
return types.at(i);
}
-PokeMod::Type& PokeMod::Pokemod::getType(const unsigned i) throw(IndexException)
+Type& Pokemod::getType(const unsigned i) throw(IndexException)
{
if (getTypeCount() <= i)
throw(IndexException("Pokemod"));
return types[i];
}
-const PokeMod::Type& PokeMod::Pokemod::getTypeByID(const unsigned i) const throw(IndexException)
+const Type& Pokemod::getTypeByID(const unsigned i) const throw(IndexException)
{
return getType(getTypeIndex(i));
}
-PokeMod::Type& PokeMod::Pokemod::getTypeByID(const unsigned i) throw(IndexException)
+Type& Pokemod::getTypeByID(const unsigned i) throw(IndexException)
{
return getType(getTypeIndex(i));
}
-unsigned PokeMod::Pokemod::getTypeIndex(const unsigned _id) const
+unsigned Pokemod::getTypeIndex(const unsigned _id) const
{
for (unsigned i = 0; i < getTypeCount(); ++i)
{
@@ -1965,12 +1977,12 @@ unsigned PokeMod::Pokemod::getTypeIndex(const unsigned _id) const
return UINT_MAX;
}
-unsigned PokeMod::Pokemod::getTypeCount() const
+unsigned Pokemod::getTypeCount() const
{
return types.size();
}
-PokeMod::Type& PokeMod::Pokemod::newType()
+Type& Pokemod::newType()
{
unsigned i;
types.append(Type(*this, i = getNewTypeId()));
@@ -1979,7 +1991,7 @@ PokeMod::Type& PokeMod::Pokemod::newType()
return types[getTypeCount() - 1];
}
-PokeMod::Type& PokeMod::Pokemod::newType(const QString& fname)
+Type& Pokemod::newType(const QString& fname)
{
unsigned i;
types.append(Type(*this, fname, i = getNewTypeId()));
@@ -1988,7 +2000,7 @@ PokeMod::Type& PokeMod::Pokemod::newType(const QString& fname)
return types[getTypeCount() - 1];
}
-PokeMod::Type& PokeMod::Pokemod::newType(const Type& t)
+Type& Pokemod::newType(const Type& t)
{
unsigned i;
types.append(Type(*this, t, i = getNewTypeId()));
@@ -1997,7 +2009,7 @@ PokeMod::Type& PokeMod::Pokemod::newType(const Type& t)
return types[getTypeCount() - 1];
}
-void PokeMod::Pokemod::deleteType(const unsigned i) throw(IndexException)
+void Pokemod::deleteType(const unsigned i) throw(IndexException)
{
if (getTypeCount() <= i)
throw(IndexException("Pokemod"));