summaryrefslogtreecommitdiffstats
path: root/pokescripting/ItemWrapper.h
diff options
context:
space:
mode:
Diffstat (limited to 'pokescripting/ItemWrapper.h')
-rw-r--r--pokescripting/ItemWrapper.h37
1 files changed, 4 insertions, 33 deletions
diff --git a/pokescripting/ItemWrapper.h b/pokescripting/ItemWrapper.h
index 124f7dda..65b71239 100644
--- a/pokescripting/ItemWrapper.h
+++ b/pokescripting/ItemWrapper.h
@@ -19,7 +19,6 @@
#define __POKESCRIPTING_ITEMWRAPPER__
// Pokescripting includes
-#include "ItemTypeWrapper.h"
#include "ObjectWrapper.h"
// Pokemod includes
@@ -27,6 +26,9 @@
namespace Pokescripting
{
+// Forward declarations
+class ItemTypeWrapper;
+
class POKESCRIPTING_EXPORT ItemWrapper : public ObjectWrapper
{
Q_OBJECT
@@ -44,44 +46,13 @@ class POKESCRIPTING_EXPORT ItemWrapper : public ObjectWrapper
ItemTypeWrapper* type();
int price() const;
QString description() const;
+ Pokemod::Script script() const;
private:
ItemWrapper(const Pokemod::Item* item, QObject* parent);
ItemWrapper& operator=(const ItemWrapper& rhs);
const Pokemod::Item* m_item;
};
-
-inline ItemWrapper::ItemWrapper(const Pokemod::Item* item, QObject* parent) :
- ObjectWrapper(item, parent),
- m_item(item)
-{
-}
-
-inline QString ItemWrapper::name() const
-{
- return m_item->name();
-}
-
-inline bool ItemWrapper::sellable() const
-{
- return m_item->sellable();
-}
-
-inline ItemTypeWrapper* ItemWrapper::type()
-{
- return ItemTypeWrapper::create(pokemod()->itemTypeById(m_item->type()), this);
-}
-
-inline int ItemWrapper::price() const
-{
- return m_item->price();
-}
-
-inline QString ItemWrapper::description() const
-{
- return m_item->description();
-}
-
}
#endif