setStatValue: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl> " to "")
m (Text replacement - " *\| *([Cc]omments|COMMENTS|Game|[Gg]ame [Nn]ame( +[0-9])?|Game [Vv]ersion( +[0-9])?|Game Version \(number surrounded by NO SPACES\)|Arguments in MP|MP[Aa]rg|Multiplayer Arguments( \("local" or "global"\))?|Effects|Execution|Effects...)
Line 1: Line 1:
{{Command|Comments=
{{Command


| arma3 |Game name=
| arma3


|1.18|Game version=
|1.18


|gr1= System |GROUP1=
|gr1= System


| Sets a value to a given stat. <br>
| Sets a value to a given stat. <br>
Line 11: Line 11:
Its important to note that most Stats are restricted to scripts and missions in certain paths.<br>
Its important to note that most Stats are restricted to scripts and missions in certain paths.<br>
For example "ExpWarlockDown" is restricted to scripts in any subdirectory of <tt>"a3\Missions_F_Exp\Campaign\Missions\"</tt>
For example "ExpWarlockDown" is restricted to scripts in any subdirectory of <tt>"a3\Missions_F_Exp\Campaign\Missions\"</tt>
|DESCRIPTION=


| [[setStatValue]] [name, value] |SYNTAX=


|p1= [name, value]: [[Array]] |PARAMETER1=
| [[setStatValue]] [name, value]


|p2= name: [[String]] |PARAMETER2=
|p1= [name, value]: [[Array]]


|p3= value: [[Number]] |PARAMETER3=
|p2= name: [[String]]


| [[Boolean]] |RETURNVALUE=
|p3= value: [[Number]]
 
| [[Boolean]]
   
   
|x1= <code>[[setStatValue]] ["ExpWarlockDown", 1]; {{cc|Unlocks the "Warlock Down" Steam achivement}}</code> |EXAMPLE1=
|x1= <code>[[setStatValue]] ["ExpWarlockDown", 1]; {{cc|Unlocks the "Warlock Down" Steam achivement}}</code>


| [[getStatValue]], [[Arma 3 Stat Names]] |SEEALSO=
| [[getStatValue]], [[Arma 3 Stat Names]]
}}
}}


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

Revision as of 11:10, 18 January 2021

Hover & click on the images for description

Description

Description:
Sets a value to a given stat.
A list of possible StatNames can be found here: Arma 3 Stat Names
Its important to note that most Stats are restricted to scripts and missions in certain paths.
For example "ExpWarlockDown" is restricted to scripts in any subdirectory of "a3\Missions_F_Exp\Campaign\Missions\"
Groups:
System

Syntax

Syntax:
setStatValue [name, value]
Parameters:
[name, value]: Array
name: String
value: Number
Return Value:
Boolean

Examples

Example 1:
setStatValue ["ExpWarlockDown", 1]; // Unlocks the "Warlock Down" Steam achivement

Additional Information

See also:
getStatValueArma 3 Stat Names

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

Bottom Section