diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-25 18:05:40 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-25 18:05:40 +0000 |
commit | e7153a55c1392f478faa0522c7f62ded1c115b3a (patch) | |
tree | 5b694367c254201d171fa9155db5d2ad7cebd793 /src/map/itemdb.h | |
parent | 1d675068f04afe6ab0829e99a32d0179c5183431 (diff) | |
download | hercules-e7153a55c1392f478faa0522c7f62ded1c115b3a.tar.gz hercules-e7153a55c1392f478faa0522c7f62ded1c115b3a.tar.bz2 hercules-e7153a55c1392f478faa0522c7f62ded1c115b3a.tar.xz hercules-e7153a55c1392f478faa0522c7f62ded1c115b3a.zip |
- Modified and simplified the random item group format. It now is <GroupID>,<ItemID>,<Rate>, where Rate normally is 1, greater numbers is the equivalent of adding the line multiple times.
- Added constants to identify all groups to db/const.txt
- Cleaned up and updated item_db to use these new constants (warning: item_db.sql needs to be updated!)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6275 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/itemdb.h')
-rw-r--r-- | src/map/itemdb.h | 38 |
1 files changed, 33 insertions, 5 deletions
diff --git a/src/map/itemdb.h b/src/map/itemdb.h index 88741b3b6..c439782e7 100644 --- a/src/map/itemdb.h +++ b/src/map/itemdb.h @@ -5,6 +5,7 @@ #define _ITEMDB_H_
#include "map.h"
+#define MAX_RANDITEM 10000
struct item_data {
int nameid;
@@ -53,16 +54,43 @@ struct item_data { int view_id;
};
-struct random_item_data {
- int nameid;
- int per;
-};
-
struct item_group {
+ int nameid[MAX_RANDITEM];
int qty; //Counts amount of items in the group.
int id[30]; // 120 bytes
};
+enum {
+ IG_BLUEBOX=1,
+ IG_VIOLETBOX, //2
+ IG_CARDALBUM, //3
+ IG_GIFTBOX, //4
+ IG_SCROLLBOX, //5
+ IG_FINDINGORE, //6
+ IG_COOKIEBAG, //7
+ IG_POTION, //8
+ IG_HERBS, //9
+ IG_FRUITS, //10
+ IG_MEAT, //11
+ IG_CANDY, //12
+ IG_JUICE, //13
+ IG_FISH, //14
+ IG_BOXES, //15
+ IG_GEMSTONE, //16
+ IG_JELLOPY, //17
+ IG_ORE, //18
+ IG_FOOD, //19
+ IG_RECOVERY, //20
+ IG_MINERALS, //21
+ IG_TAMING, //22
+ IG_SCROLLS, //23
+ IG_QUIVERS, //24
+ IG_MASKS, //25
+ IG_ACCESORY, //26
+ IG_JEWELS, //27
+ MAX_ITEMGROUP,
+} item_group_list;
+
struct item_data* itemdb_searchname(const char *name);
int itemdb_searchname_array(struct item_data** data, int size, const char *str);
struct item_data* itemdb_load(int nameid);
|