Difference between revisions of "getFatigue"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (template:command argument fix)
m (Text replacement - "{{uc:{{PAGENAME}}}}" to "")
 
(9 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{Command|= Comments
+
{{Command|Comments=
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
| arma3 |= Game name
+
| arma3 |Game name=
|0.50|= Game version
+
|0.50|Game version=
|arg= global|= Arguments in MP
+
|arg= global|Multiplayer Arguments=
 +
 
 +
|gr1= Stamina System |GROUP1=
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
Line 25: Line 27:
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
| [[setFatigue]], [[enableFatigue]] |SEEALSO=  
+
| [[setFatigue]], [[enableFatigue]], [[getStamina]] |SEEALSO=  
  
 
|  |MPBEHAVIOUR=  
 
|  |MPBEHAVIOUR=  
Line 35: Line 37:
 
<!-- Note Section BEGIN -->
 
<!-- Note Section BEGIN -->
  
<dt class="note">'''[[User:Killzone_Kid|Killzone_Kid]]'''<dd class="note">
+
<dt class="note">[[User:Killzone_Kid|Killzone_Kid]]<dd class="note">
<br>
 
 
[[getFatigue]] can be applied to remote unit however it will not read the changes made to unit's fatigue with [[setFatigue]] command. Only natural changes resulting from unit moving will be counted. When applied to local unit, it will read resulting value of natural fatigue combined with artificial changes added locally by [[setFatigue]]. In short, the server wouldn't know the correct value of remote unit's fatigue if you used [[setFatigue]] on the unit prior.<br>
 
[[getFatigue]] can be applied to remote unit however it will not read the changes made to unit's fatigue with [[setFatigue]] command. Only natural changes resulting from unit moving will be counted. When applied to local unit, it will read resulting value of natural fatigue combined with artificial changes added locally by [[setFatigue]]. In short, the server wouldn't know the correct value of remote unit's fatigue if you used [[setFatigue]] on the unit prior.<br>
  
Line 46: Line 47:
 
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
 
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]]
[[Category:Command_Group:_Object_Information|{{uc:{{PAGENAME}}}}]]
 

Latest revision as of 17:03, 27 September 2020

Introduced with Arma 3 version 0.500.50Arguments of this scripting command don't have to be local to the client the command is executed on
Hover & click on the images for descriptions

Description

Description:
Returns fatigue of given unit.

Syntax

Syntax:
getFatigue unit
Parameters:
unit: Object
Return Value:
Number

Examples

Example 1:
value = getFatigue player;
Example 2:
if (getFatigue player < 0.5) then { player sideChat "I'm good to go!" };

Additional Information

See also:
setFatigueenableFatiguegetStamina
Groups:
Stamina System

Notes

i
Only post proven facts here. Report bugs on the Feedback Tracker and discuss on the Arma Discord or on the Forums.

Notes

Killzone_Kid
getFatigue can be applied to remote unit however it will not read the changes made to unit's fatigue with setFatigue command. Only natural changes resulting from unit moving will be counted. When applied to local unit, it will read resulting value of natural fatigue combined with artificial changes added locally by setFatigue. In short, the server wouldn't know the correct value of remote unit's fatigue if you used setFatigue on the unit prior.

Bottom Section