fuel: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "_{10,} " to "") |
Lou Montana (talk | contribs) m (Text replacement - " *\| *([Cc]omments|COMMENTS|Game|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments( \("local" or "global"\))?|Effects|Multiplayer Effects( \("local" or "global"\))?|Multiplayer Exe...) |
||
Line 1: | Line 1: | ||
{{Command | {{Command | ||
| ofp | | ofp | ||
|1.00 | |1.00 | ||
|arg= global | |arg= global | ||
|gr1= Object Manipulation | |gr1= Object Manipulation | ||
| Checks how much fuel is left in the gas tank of a vehicle. | | Checks how much fuel is left in the gas tank of a vehicle. | ||
| '''fuel''' vehicle | | '''fuel''' vehicle | ||
|p1= vehicle: [[Object]] | |p1= vehicle: [[Object]] | ||
| [[Number]] - | | [[Number]] - | ||
The returned number is in range 0 (empty tank) to 1 (full tank). | The returned number is in range 0 (empty tank) to 1 (full tank). | ||
|x1= <code>[[if]] ([[fuel]] [[vehicle]] [[player]] == 0) [[then]] {[[hint]] "The vehicle is out of fuel!"};</code> | |x1= <code>[[if]] ([[fuel]] [[vehicle]] [[player]] == 0) [[then]] {[[hint]] "The vehicle is out of fuel!"};</code> | ||
| [[setFuel]], [[setFuelCargo]], [[getFuelCargo]] | | [[setFuel]], [[setFuelCargo]], [[getFuelCargo]] | ||
}} | }} |
Revision as of 00:36, 18 January 2021
Description
- Description:
- Checks how much fuel is left in the gas tank of a vehicle.
- Groups:
- Object Manipulation
Syntax
- Syntax:
- fuel vehicle
- Parameters:
- vehicle: Object
- Return Value:
- Number - The returned number is in range 0 (empty tank) to 1 (full tank).
Examples
Additional Information
- See also:
- setFuelsetFuelCargogetFuelCargo
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note
Notes
- UNN
- Vehicles refuelled in game with the Fuel trucks e.t.c never get completely refuelled. After refuelling, rather than returning a value of 1 when the fuel command is called. They return a value greater than 0.98 and less than 1.
Bottom Section
- Posted on December 19, 2020 - 18:10 (UTC)
- fusselwurm
-
returns
- 1 for units (dead or alive)
- 0 for objNull
Categories:
- Scripting Commands
- Introduced with Operation Flashpoint version 1.00
- Operation Flashpoint: New Scripting Commands
- Operation Flashpoint: Scripting Commands
- Command Group: Object Manipulation
- Scripting Commands OFP 1.99
- Scripting Commands OFP 1.96
- Scripting Commands OFP 1.46
- ArmA: Armed Assault: Scripting Commands
- Arma 2: Scripting Commands
- Arma 3: Scripting Commands
- Take On Helicopters: Scripting Commands