Closed StuxxyOfficial closed 2 years ago
After finishing refuel with fuelcan all actions and prompts stop working - with vehicle and with stations. Restarting resource brings them back. No errors server or client side.
And yes, 'pump' changed to 1, 'can' to 2 and ox.refillValue to Config.refillValue
Okey, after intense debugging I found an error.
Add local candeduction = 0
after local nearestPump
and change local candeduction = 0
in first loop to candeduction = 0
Okey, after intense debugging I found an error. Add
local candeduction = 0
afterlocal nearestPump
and changelocal candeduction = 0
in first loop tocandeduction = 0
I'm not sure how that fixes anything, that variable doesn't need to be global, its only referenced inside that function.
Implemented in some way, shape and form in https://github.com/overextended/ox_fuel/commit/6c7d670383f67c6251e73c0f625ef010ddcc97f5.
Finds inventory slot of WEAPON_PETROLCAN in players hand then deducts durability based on amount of fuel put into vehicle. also added logic for cancelling fueling if durability hits 0.