Page 1 of 1

Item related LUA functions

Posted: Mon Aug 12, 2013 5:21 pm
by thefoof
It occured to me today we had no way of retrieving item pointers through LUA, so I coded some up :D. I also fixed a bug in HasItem() where it was running a check to see if the item was in equipped slots, but it never returned the true or false from that check.

GetEquippedItemBySlot(Player, slot_id)

GetEquippedItemByID(Player, item_id)

GetItemByID(Player, item_id, count, include_bank 0 = false 1 = true)


These are used exactly how they look, just pass a player pointer for Player, and it checks that player for item pointers using the given values, the function then returns a pointer to that item.

Re: Item related LUA functions

Posted: Tue Aug 13, 2013 1:08 pm
by John Adams
Not to be a pest... but... Wiki? :)