summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/CMakeLists.txt2
-rw-r--r--src/Makefile.am2
-rw-r--r--src/resources/item/cardslist.cpp25
-rw-r--r--src/resources/item/cardslist.h48
4 files changed, 77 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 6984556c4..53e3016a1 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -1011,6 +1011,8 @@ SET(SRCS
resources/inventory/complexinventory.h
resources/inventory/inventory.cpp
resources/inventory/inventory.h
+ resources/item/cardslist.cpp
+ resources/item/cardslist.h
resources/item/complexitem.cpp
resources/item/complexitem.h
resources/item/item.cpp
diff --git a/src/Makefile.am b/src/Makefile.am
index b262d71ba..cc2060024 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -805,6 +805,8 @@ manaplus_SOURCES += main.cpp \
resources/inventory/inventory.h \
textcommand.cpp \
textcommand.h \
+ resources/item/cardslist.cpp \
+ resources/item/cardslist.h \
resources/item/complexitem.cpp \
resources/item/complexitem.h \
resources/item/item.cpp \
diff --git a/src/resources/item/cardslist.cpp b/src/resources/item/cardslist.cpp
new file mode 100644
index 000000000..c26d023b3
--- /dev/null
+++ b/src/resources/item/cardslist.cpp
@@ -0,0 +1,25 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2016 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "resources/item/cardslist.h"
+
+#include "debug.h"
+
+CardsList zeroCards(0, 0, 0, 0);
diff --git a/src/resources/item/cardslist.h b/src/resources/item/cardslist.h
new file mode 100644
index 000000000..f8a7fee3a
--- /dev/null
+++ b/src/resources/item/cardslist.h
@@ -0,0 +1,48 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2004-2009 The Mana World Development Team
+ * Copyright (C) 2009-2010 The Mana Developers
+ * Copyright (C) 2011-2016 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef RESOURCES_ITEM_CARDSLIST_H
+#define RESOURCES_ITEM_CARDSLIST_H
+
+#include "const/resources/item/cards.h"
+
+#include "localconsts.h"
+
+struct CardsList final
+{
+ CardsList(const int card0,
+ const int card1,
+ const int card2,
+ const int card3)
+ {
+ cards[0] = card0;
+ cards[1] = card1;
+ cards[2] = card2;
+ cards[3] = card3;
+ }
+
+ int cards[maxCards];
+};
+
+extern CardsList zeroCards;
+
+#endif // RESOURCES_ITEM_CARDSLIST_H