BIS fnc setServerVariable: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - " \| *(\[\[[a-zA-Z ]+\]\].+) \|x1=" to " |r1=$1 |x1=") |
Lou Montana (talk | contribs) m (Some wiki formatting) |
||
(13 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
{{RV|type=function | {{RV|type=function | ||
| arma3 | |game1= arma3 | ||
|version1= 1.00 | |||
|1.00 | |||
|gr1= Variables | |gr1= Variables | ||
| Set variable stored only on server. Clients can the download it using [[BIS_fnc_getServerVariable]]. Used when you want to share variables only to specific clients to prevent large traffic. | |descr= Set variable stored only on server. Clients can the download it using [[BIS_fnc_getServerVariable]]. Used when you want to share variables only to specific clients to prevent large traffic. | ||
| [namespace, varName, value] call [[BIS_fnc_setServerVariable]] | |s1= [namespace, varName, value] call [[BIS_fnc_setServerVariable]] | ||
|p1= namespace: [[Namespace]] | |p1= namespace: [[Namespace]], [[Object]] or [[Group]] - (Optional, default [[missionNamespace]]) | ||
|p2= varName: [[String]] - variable name | |p2= varName: [[String]] - variable name | ||
Line 17: | Line 16: | ||
|p3= value: [[Anything]] - variable value | |p3= value: [[Anything]] - variable value | ||
|r1=[[Boolean]] - [[true]] when done | |r1= [[Boolean]] - [[true]] when done | ||
|x1= < | |x1= <sqf>[nil, "playerHealth", damage player] call BIS_fnc_setServerVariable;</sqf> | ||
|x2= < | |x2= <sqf>[player, "playerHealth", damage player] call BIS_fnc_setServerVariable;</sqf> | ||
|seealso= [[BIS_fnc_getServerVariable]] | |seealso= [[BIS_fnc_getServerVariable]] [[publicVariableServer]] [[publicVariableClient]] | ||
}} | }} | ||
Latest revision as of 13:34, 13 July 2022
Description
- Description:
- Set variable stored only on server. Clients can the download it using BIS_fnc_getServerVariable. Used when you want to share variables only to specific clients to prevent large traffic.
- Execution:
- call
- Groups:
- Variables
Syntax
- Syntax:
- [namespace, varName, value] call BIS_fnc_setServerVariable
- Parameters:
- namespace: Namespace, Object or Group - (Optional, default missionNamespace)
- varName: String - variable name
- value: Anything - variable value
- Return Value:
- Boolean - true when done
Examples
- Example 1:
- Example 2:
Additional Information
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