diff options
| author | Ben Boeckel <MathStuf@gmail.com> | 2008-04-17 23:34:36 +0000 |
|---|---|---|
| committer | Ben Boeckel <MathStuf@gmail.com> | 2008-04-17 23:34:36 +0000 |
| commit | 6679f5cffa9d35a23b76605ddfbf3257f882b6ee (patch) | |
| tree | c8e41854a60b64e8569939bca6b827807175ef9a /pokemod/Item.cpp | |
| parent | 05980e883719b1c8ebde1bd2fcbf4f8c16df7ad6 (diff) | |
[FIX] Frac -> Fraction
[FIX] ImageCache and Ini removed
[FIX] Fraction/Point widgets moved to pokemodr
[FIX] Copy ctors made for pokemod classes
[FIX] Ctors in pokemod fixed
[FIX] Copyright headers fixed in pokemodr
[FIX] PokeModr updated to new API and fixed in some places
git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@99 6ecfd1a5-f3ed-3746-8530-beee90d26b22
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]; } |
