diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-01-23 18:13:42 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-01-23 18:13:42 +0300 |
commit | 80956ecdab280f24708981f71bac50ec23587311 (patch) | |
tree | e11766d931bb8b22b9024e052ece9b01383100ff /src/emap/craftconf.h | |
parent | 722d18daaceebbebfd6a0faf8ad4b0497d2599d1 (diff) | |
download | plugin-80956ecdab280f24708981f71bac50ec23587311.tar.gz plugin-80956ecdab280f24708981f71bac50ec23587311.tar.bz2 plugin-80956ecdab280f24708981f71bac50ec23587311.tar.xz plugin-80956ecdab280f24708981f71bac50ec23587311.zip |
Move craft conf related things into separate file.
Also move itempair struct into separate file.
Diffstat (limited to 'src/emap/craftconf.h')
-rw-r--r-- | src/emap/craftconf.h | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/src/emap/craftconf.h b/src/emap/craftconf.h new file mode 100644 index 0000000..b9f4a73 --- /dev/null +++ b/src/emap/craftconf.h @@ -0,0 +1,48 @@ +// Copyright (c) Copyright (c) Hercules Dev Team, licensed under GNU GPL. +// Copyright (c) 2014 - 2015 Evol developers + +#ifndef EVOL_MAP_CRAFTCONF +#define EVOL_MAP_CRAFTCONF + +#include "common/db.h" + +#include "emap/const/craft.h" + +#include "emap/struct/itempair.h" + +VECTOR_STRUCT_DECL(craft_items_collection, struct item_pair); + +struct craft_db_inventory +{ + struct item_pair items[craft_inventory_size]; +}; + +struct craft_db_entry +{ + int id; + char name[32]; + VECTOR_DECL(struct craft_db_inventory) inventories; + struct craft_items_collection create_items; + struct craft_items_collection delete_items; + struct craft_items_collection required_items; + struct craft_items_collection required_equips; + struct craft_items_collection required_skills; + struct craft_items_collection required_quests; + int priority; + int price; + int level; + int flag; +}; + +enum craft_field_type +{ + CRAFT_ITEM, + CRAFT_QUEST, + CRAFT_SKILL, + CRAFT_BOOL +}; + +void do_init_craftconf(void); +void do_final_craftconf(void); + +#endif // EVOL_MAP_CRAFTCONF |