ed
This commit is contained in:
		
							parent
							
								
									510e3ffcf2
								
							
						
					
					
						commit
						f43cf424cf
					
				
					 305 changed files with 34683 additions and 0 deletions
				
			
		|  | @ -0,0 +1,29 @@ | |||
| ---@diagnostic disable: duplicate-set-field | ||||
| local resourceName = "Renewed-Fuel" | ||||
| if GetResourceState(resourceName) == 'missing' then return end | ||||
| Fuel = Fuel or {} | ||||
|  | ||||
| ---This will get the name of the Fuel being used (if a supported Fuel). | ||||
| ---@return string | ||||
| Fuel.GetResourceName = function() | ||||
|     return resourceName | ||||
| end | ||||
|  | ||||
| ---This will get the fuel level of the vehicle. | ||||
| ---@param vehicle number The vehicle entity ID. | ||||
| ---@return number fuel The fuel level of the vehicle. | ||||
| Fuel.GetFuel = function(vehicle) | ||||
|     if not DoesEntityExist(vehicle) then return 0.0 end | ||||
|     return exports['Renewed-Fuel']:GetFuel(vehicle) | ||||
| end | ||||
|  | ||||
| ---This will set the fuel level of the vehicle. | ||||
| ---@param vehicle number The vehicle entity ID. | ||||
| ---@param fuel number The fuel level to set. | ||||
| ---@return nil | ||||
| Fuel.SetFuel = function(vehicle, fuel, type) | ||||
|     if not DoesEntityExist(vehicle) then return end | ||||
|     return exports['Renewed-Fuel']:SetFuel(vehicle, fuel) | ||||
| end | ||||
|  | ||||
| return Fuel | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Nordi98
						Nordi98