BIS fnc getParamValue: Difference between revisions

From Bohemia Interactive Community
m (Text replacement - " *\|= * " to " ")
m (Some wiki formatting)
 
(26 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Function|Comments=
{{RV|type=function


| arma3 |Game name=
|game1= arma3
|version1= 1.00


|1.00|Game version=
|gr1= Mission Parameters


|gr1= Mission Parameters |GROUP1=
|descr= Returns the value of the named {{Link|Mission Parameters|mission parameter}}.
This function is global and will return selected param value on any PC including JIP. For backward compatibility it also supports "param1" and "param2".


|Returns the value of mission param given by the class name. This function is global and will return selected param value on any PC including JIP. For backward compatibility it also supports "param1" and "param2".  |DESCRIPTION=
|s1= paramClass call [[BIS_fnc_getParamValue]]


| paramClass call [[BIS_fnc_getParamValue]]; |SYNTAX=
|p1= paramClass: [[String]] - class name of one of [[Mission Parameters]]


|p1= paramClass: [[String]] - class name of one of [[Arma 3 Mission Parameters]]|PARAMETER1=
|p2= defalutValue: [[Number]] - (Optional, default 0) default value to return if ''paramClass does not exist


|[[Number]] - param value. Default: 0|RETURNVALUE=
|r1= [[Number]] - param value


|s2= [paramClass, defaultValue] call [[BIS_fnc_getParamValue]]; |SYNTAX2=
|x1= <sqf>scoreToWin = "ScoreToWin" call BIS_fnc_getParamValue;</sqf>


|p21= paramClass: [[String]] - class name of one of [[Arma 3 Mission Parameters]]|PARAMETER21=
|x2= <sqf>_viewDistance = ["TAG_viewDistance", 500] call BIS_fnc_getParamValue;</sqf>
|p22= defaultValue (Optional): [[Number]] - default value to return if param doesn't exist|PARAMETER22=


|r2=[[Number]] - param value. Default: 0 |RETURNVALUE2=
|x3= <sqf>
if (param1 == ("param1" call BIS_fnc_getParamValue)) then
{
hint "Old timer";
};
</sqf>


|x1= <code>_viewDistance = "ViewDistance" [[call]] [[BIS_fnc_getParamValue]];</code> |Example1=
|seealso= [[Mission Parameters]] [[getMissionConfigValue]] [[getMissionConfig]] [[BIS_fnc_storeParamsValues]]
 
|x2= <code>_viewDistance = ["ViewDistance", 2] [[call]] [[BIS_fnc_getParamValue]];</code>
 
| [[Arma 3 Mission Parameters]]|SEEALSO=
}}
}}
<h3 style="display:none">Bottom Section</h3>
[[Category:Functions|{{uc:getParamValue}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:getParamValue}}]]

Latest revision as of 13:08, 14 February 2026

Hover & click on the images for description

Description

Description:
Returns the value of the named mission parameter. This function is global and will return selected param value on any PC including JIP. For backward compatibility it also supports "param1" and "param2".
Execution:
call
Groups:
Mission Parameters

Syntax

Syntax:
paramClass call BIS_fnc_getParamValue
Parameters:
paramClass: String - class name of one of Mission Parameters
defalutValue: Number - (Optional, default 0) default value to return if paramClass does not exist
Return Value:
Number - param value

Examples

Example 1:
scoreToWin = "ScoreToWin" call BIS_fnc_getParamValue;
Example 2:
_viewDistance = ["TAG_viewDistance", 500] call BIS_fnc_getParamValue;
Example 3:
if (param1 == ("param1" call BIS_fnc_getParamValue)) then { hint "Old timer"; };

Additional Information

See also:
Mission Parameters getMissionConfigValue getMissionConfig BIS_fnc_storeParamsValues

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord.
Only post proven facts here! Add Note