damage: Difference between revisions
Jump to navigation
Jump to search
Austin medic (talk | contribs) No edit summary |
m (code tags; wiki linked) |
||
Line 20: | Line 20: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
|x1= < | |x1= <code>[[?]] (([[damage]] [[player]])>0.1) : [[player]] [[groupChat]] "I'm hurt! Medic!"</code> |= Example 1 | ||
|x2= < | |x2= <code>[[if]] (([[damage]] [[player]]) > 0.1) [[then]] { | ||
if ((damage player) > 0.1) then | [[player]] [[groupChat]] "I'm hurt! Medic!"; | ||
{ | };</code> |= Example 2 | ||
player groupChat "I'm hurt! Medic!"; | |||
};</ | |||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Revision as of 15:48, 25 December 2014
Description
- Description:
- Return the damage value of an object.
- Groups:
- Uncategorised
Syntax
- Syntax:
- Number = damage object
- Parameters:
- object: Object
- Return Value:
- Number - The returned number is in range 0 (healthy) to 1 (dead).
Examples
- Example 1:
? ((damage player)>0.1) : player groupChat "I'm hurt! Medic!"
- Example 2:
if ((damage player) > 0.1) then { player groupChat "I'm hurt! Medic!"; };
Additional Information
- See also:
- setDamagesetDammagegetDammagesetHit
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
Categories:
- Scripting Commands
- Introduced with Operation Flashpoint version 1.5
- Operation Flashpoint: New Scripting Commands
- Operation Flashpoint: Scripting Commands
- Command Group: Uncategorised
- Scripting Commands OFP 1.99
- Scripting Commands OFP 1.96
- Scripting Commands ArmA
- Command Group: Object Information
- Scripting Commands ArmA2
- Scripting Commands Arma 3
- Scripting Commands Take On Helicopters