canFire: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 1: Line 1:
[[Category:Scripting Commands|CANFIRE]]
{{Command|= Comments
[[Category:Scripting Commands OFP 1.96|CANFIRE]]
____________________________________________________________________________________________
[[Category:Scripting Commands OFP 1.46|CANFIRE]]
[[Category:Scripting Commands ArmA|CANFIRE]]


| ofp |= Game name


<h2 style="color:#000066"> '''canFire ''vehicle'''''</h2>
|1.00|= Game version


|arg= global |= Arguments in MP
____________________________________________________________________________________________


'''Operand types:'''
| Returns if the given vehicle is still able to fire. This command checks only the damage value, not the ammo! |= Description
____________________________________________________________________________________________


'''vehicle:''' [[Object]]
| '''canFire''' vehicle |= Syntax


'''Type of returned value:'''
|p1= vehicle: [[Object]] |= Parameter 1


[[Boolean]]
| [[Boolean]]
true if it's still able to fire, false if not |= Return value
____________________________________________________________________________________________
 
|x1= <pre>?!(canFire tank) : player sideChat "Tank disabled!"</pre> |= Example 1
____________________________________________________________________________________________


'''Description:'''
| [[canMove]], [[canStand]] |= See also


Check if given '''vehicle''' is able to fire.
}}


Does not check for ammo, only for damage.
<h3 style="display:none">Notes</h3>
<dl class="command_description">
<!-- Note Section BEGIN -->


<!-- Note Section END -->
</dl>


'''Example:'''
<h3 style="display:none">Bottom Section</h3>


? '''canFire''' ([[vehicle]] [[player]]) : [[goto]] "target"
[[Category:Scripting Commands|CANFIRE]]
[[Category:Scripting Commands OFP 1.96|CANFIRE]]
[[Category:Scripting Commands OFP 1.46|CANFIRE]]
[[Category:Scripting Commands ArmA|CANFIRE]]

Revision as of 23:37, 1 August 2006

Hover & click on the images for description

Description

Description:
Returns if the given vehicle is still able to fire. This command checks only the damage value, not the ammo!
Groups:
Uncategorised

Syntax

Syntax:
canFire vehicle
Parameters:
vehicle: Object
Return Value:
Boolean - true if it's still able to fire, false if not

Examples

Example 1:
?!(canFire tank) : player sideChat "Tank disabled!"

Additional Information

See also:
canMovecanStand

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

Bottom Section