jimathy / jim-mining

FiveM QBCore Script for Mining
158 stars 108 forks source link

Attempt to index a nil value (field '?') and QBCore.Shared errors #28

Closed rxnm closed 1 year ago

rxnm commented 1 year ago

Hey mate, just came across your script, thank you very much, first of all, it's great and especially for FREE. Though not a game-breaking bug I have some feedback for you. The first one is (Attempt to index a nil value (field '?').

And the 2nd one is an error about QBCore.Shared.Items. (imgs attached)

hhhh Screenshot_1

jimathy commented 1 year ago

Well all I can assume is you haven't added the items that come with the script

or you've made a mistake in the items.lua

rxnm commented 1 year ago

Nope, that is not the problem mate, I can see ALL the items in the game, I can even mine, sell, etc etc... it's all working, BUT those errors are being spammed upon starting the server up. Like I said it isn't game-breaking, just errors in the log. On the CFX Forums someone else is reporting the same problem, it seems to be something with the crafting side.

Crafting your items doesn't work either, such as making jewelry etc, other than that it's all good.

As you can see:

Screenshot_1

Funny how it says the items are missing BUT they are clearly there in the game, haha

xViperAG commented 1 year ago

Is there a comma next to whatever is above the -- Jim-Mining ?

rxnm commented 1 year ago

Yes, mate there is, like I said, from experience, this is something in the code/crafting area?!?

jimathy commented 1 year ago

Ok, so it really shouldn't be spamming them if you can spawn them, unless you're starting the script before qb-core?

otherwise if its throwing an error when trying to craft, most likely a missing ingredient

rxnm commented 1 year ago

No worries, I can see what has happened lol... the (readme) is outdated compared to what the list of items is on your GitHub, updated the list of items which is on here now and its working fine, lol sorry mate. Thanks :)