setDammage: Difference between revisions

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


| ofp |= Game name


<h2 style="color:#000066">'''''object'' setDammage ''damage'''''</h2>
|1.00|= Game version
____________________________________________________________________________________________


| Damage / repair object. Damages or repairs the object. Damage 0 means fully functional, damage 1 means completely destroyed / dead. See also [[getDammage]] Note: This function is identical to [[setDamage]].
[[setDamage]] was introduced to fix a spelling error in this operator's name.
Note: Setting a unit's damage to a negative value will set their health to full, but impair their aim. |= Description
____________________________________________________________________________________________


'''Operand types:'''
| object '''setDammage''' damage |= Syntax


'''object:''' [[Object]]
|p1= object: [[Object]] |= Parameter 1


'''damage:''' [[Number]]
|p2= damage: [[Number]] |= Parameter 2


'''Type of returned value:'''
| [[Nothing]] |= Return value
____________________________________________________________________________________________
 
|x1= <pre>soldier1 setDammage 1</pre> |= Example 1
____________________________________________________________________________________________


[[Nothing]]
|  |= See also


'''Description:'''
}}


'''Damage / repair object'''.
<h3 style="display:none">Notes</h3>
<dl class="command_description">
<!-- Note Section BEGIN -->


Damages or repairs the object.
<!-- Note Section END -->
</dl>


Damage 0 means fully functional, damage 1 means completely destroyed / dead.
<h3 style="display:none">Bottom Section</h3>
 
[[Category:Scripting Commands|SETDAMMAGE]]
See also [[getDammage]]
[[Category:Scripting Commands OFP 1.96|SETDAMMAGE]]
 
[[Category:Scripting Commands OFP 1.46|SETDAMMAGE]]
'''Note:''' This function is identical to [[setDamage]].<br>
[[Category:Scripting Commands ArmA|SETDAMMAGE]]
[[setDamage]] was introduced to fix a spelling error in this operator's name.<br>
'''Note:''' Setting a unit's damage to a negative value will set their health to full, but impair their aim.
 
 
'''Example:<br>'''
 
soldier1 '''setDammage''' 1

Revision as of 00:09, 2 August 2006

Hover & click on the images for description

Description

Description:
Damage / repair object. Damages or repairs the object. Damage 0 means fully functional, damage 1 means completely destroyed / dead. See also getDammage Note: This function is identical to setDamage. setDamage was introduced to fix a spelling error in this operator's name. Note: Setting a unit's damage to a negative value will set their health to full, but impair their aim.
Groups:
Uncategorised

Syntax

Syntax:
object setDammage damage
Parameters:
object: Object
damage: Number
Return Value:
Nothing

Examples

Example 1:
soldier1 setDammage 1

Additional Information

See also:
See also needed

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