diff options
Diffstat (limited to 'pokemod/Item.cpp')
| -rw-r--r-- | pokemod/Item.cpp | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/pokemod/Item.cpp b/pokemod/Item.cpp index 7fa91e02..afd4bd67 100644 --- a/pokemod/Item.cpp +++ b/pokemod/Item.cpp @@ -16,9 +16,7 @@ */ // Qt includes -#include <QDir> #include <QMap> -#include <QStringList> // Pokemod includes #include "Pokemod.h" @@ -27,6 +25,12 @@ // Header include #include "Item.h" +Item::Item(const Item& item) : + Object("Item", item.pokemod(), item.id()) +{ + *this = item; +} + Item::Item(const Pokemod* pokemod, const int id) : Object("Item", pokemod, id), m_name(""), @@ -37,13 +41,13 @@ Item::Item(const Pokemod* pokemod, const int id) : { } -Item::Item(const Pokemod* pokemod, const Item& item, const int id) : +Item::Item(const Item& item, const Pokemod* pokemod, const int id) : Object("Item", pokemod, id) { *this = item; } -Item::Item(const Pokemod* pokemod, const QDomElement& xml, const int id) : +Item::Item(const QDomElement& xml, const Pokemod* pokemod, const int id) : Object("Item", pokemod, id) { load(xml, id); @@ -217,13 +221,13 @@ ItemEffect* Item::newEffect() ItemEffect* Item::newEffect(const QDomElement& xml) { - m_effects.append(new ItemEffect(pokemod(), xml, effectId())); + m_effects.append(new ItemEffect(xml, pokemod(), effectId())); return m_effects[effectCount() - 1]; } ItemEffect* Item::newEffect(const ItemEffect& effect) { - m_effects.append(new ItemEffect(pokemod(), effect, effectId())); + m_effects.append(new ItemEffect(effect, pokemod(), effectId())); return m_effects[effectCount() - 1]; } |
