From 6f7ad82c7a804a224fd8ca405a0ebc4b739dc3e4 Mon Sep 17 00:00:00 2001 From: Dastgir Date: Sat, 9 Mar 2019 21:57:11 +0530 Subject: Expanded getinventorylist: * getinventorylist now creates extra variable named @inventorylist_idx, which returns items corresponding inventory index. --- src/map/script.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/map') diff --git a/src/map/script.c b/src/map/script.c index 24cb8e4f4..b13e2fb76 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -14830,6 +14830,7 @@ static BUILDIN(getinventorylist) } pc->setreg(sd,reference_uid(script->add_variable("@inventorylist_expire"), j),sd->status.inventory[i].expire_time); pc->setreg(sd,reference_uid(script->add_variable("@inventorylist_bound"), j),sd->status.inventory[i].bound); + pc->setreg(sd, reference_uid(script->add_variable("@inventorylist_idx"), j), i); j++; } } -- cgit v1.2.3-70-g09d2