swag_k_dog Posted July 8, 2017 Share Posted July 8, 2017 (edited) function test() exports.inventory:addPlayerItem(source,1,1) end addCommandHandler("lol", test) when I type /lol it says in the debug: ERROR: test/test.lua:2: call: failed to call 'inventory:addPlayerItem' [string "?"] I am using the HeroInventory resource for the inventory HeroInventory wiki: https://wiki.multitheftauto.com/wiki/HeroInventory help? Edited July 8, 2017 by swag_k_dog Link to comment
mgdmgd Posted July 8, 2017 Share Posted July 8, 2017 It means the inventory:addPlayerItem isn't identified in the script or in the meta.xml. Link to comment
itHyperoX Posted July 8, 2017 Share Posted July 8, 2017 exports["inventory"]:addPlayerItem(player,ItemID, Amount) for me working Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now