summaryrefslogtreecommitdiff
path: root/src/map/quest.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-12-14 01:20:44 +0300
committerAndrei Karas <akaras@inbox.ru>2018-12-14 23:52:47 +0300
commitbc682624496b854607b8e1bd976bb317eb8b0d4f (patch)
tree57cb030d5c5d0f2865c05ea641041634f7855258 /src/map/quest.c
parent1a26402c3bd986d0bba0435bfbd62e32abf07302 (diff)
downloadhercules-bc682624496b854607b8e1bd976bb317eb8b0d4f.tar.gz
hercules-bc682624496b854607b8e1bd976bb317eb8b0d4f.tar.bz2
hercules-bc682624496b854607b8e1bd976bb317eb8b0d4f.tar.xz
hercules-bc682624496b854607b8e1bd976bb317eb8b0d4f.zip
Add inventory size field into db and using it in server.
Diffstat (limited to 'src/map/quest.c')
-rw-r--r--src/map/quest.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/quest.c b/src/map/quest.c
index f10d6847f..7a216095e 100644
--- a/src/map/quest.c
+++ b/src/map/quest.c
@@ -814,7 +814,7 @@ static bool quest_questinfo_validate_items(struct map_session_data *sd, struct q
for (int i = 0; i < VECTOR_LENGTH(qi->items); i++) {
struct questinfo_itemreq *item = &VECTOR_INDEX(qi->items, i);
int count = 0;
- for (int j = 0; j < MAX_INVENTORY; j++) {
+ for (int j = 0; j < sd->status.inventorySize; j++) {
if (sd->status.inventory[j].nameid == item->nameid)
count += sd->status.inventory[j].amount;
}