Jump to content

Attempt to compare number with nil


Recommended Posts

Im having an error ( attempt to compare number with nil ), i need some help to fix it! Thanks for all help ❤️

 

local vehFuel = dbPoll(dbQuery(database, "SELECT * FROM playersConce WHERE Account = ?", getAccountName(getPlayerAccount(source))), -1)

if vehFuel["Fuel"] > 0 then <<---- Line with the error
	setElementData(vehicleConces[source], "DNL:Combustivel", vehFuel)
else
    setElementData(vehicleConces[source], "DNL:Combustivel", 100) 
end

 

Link to post

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...