doFire: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 5: Line 5:




<h2 style="color:#000066">'''doFire ''target'''''</h2>
<h2 style="color:#000066">'''''unit'' doFire ''target'''''</h2>




'''Operand types:'''
'''Operand types:'''
'''unit:''' [[Object]] or [[Array]]


'''target:''' [[Object]]
'''target:''' [[Object]]
Line 18: Line 20:
'''Description:'''
'''Description:'''


Order unit to commence fire on given '''target''' (silent).
Orders unit to commence fire on given '''target''' (silently).


If target is [[objNull]], commence fire to current target (set using [[doTarget]] or [[commandTarget]]).
If target is [[objNull]], the unit is ordered to commence firing on its current target (set using [[doTarget]] or [[commandTarget]]).





Revision as of 12:57, 4 July 2006


unit doFire target


Operand types:

unit: Object or Array

target: Object

Type of returned value:

Nothing

Description:

Orders unit to commence fire on given target (silently).

If target is objNull, the unit is ordered to commence firing on its current target (set using doTarget or commandTarget).


Example:

soldierOne doFire objNull


Comments:

It is often helpful to use doTarget first.