BIS fnc moduleCoverMap: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "(\|[pr][0-9]+ *= *[^- ]*) *- *O([a-z ])" to "$1 - o$2") |
Lou Montana (talk | contribs) m (Some wiki formatting) |
||
Line 10: | Line 10: | ||
|eff= global | |eff= global | ||
|descr= Covers the map except for a defined area. This function was designed to be used by the [[Modules|Modules framework]], but it can also be used without the module. The effect does not move with the centerObject. | |descr= [[File:BIS_fnc_moduleCoverMap.jpg|right|500px]] | ||
Covers the map except for a defined area. This function was designed to be used by the [[Modules|Modules framework]], but it can also be used without the module. The effect does not move with the centerObject. | |||
|s1= [centerUnit,units,init] call [[BIS_fnc_moduleCoverMap]] | {{Feature|important| | ||
It is essential for the function to work that '''centerObject''' has the '''objectArea''' variable defined. | |||
<sqf>centerObject setVariable ["objectArea", [sizeX, sizeY, rotation]]</sqf> | |||
* centerObject: [[Object]] - object which is used as center | |||
* sizeX: [[Number]] - length in x in meters | |||
* sizeY: [[Number]] - length in y in meters | |||
* rotation: [[Number]] - shape's rotation in degree | |||
}} | |||
|s1= [centerUnit, units, init] call [[BIS_fnc_moduleCoverMap]] | |||
|p1= centerUnit: [[Object]] - object which is used as center | |p1= centerUnit: [[Object]] - object which is used as center | ||
Line 33: | Line 36: | ||
// can be used to dynamically change size of the area during mission | // can be used to dynamically change size of the area during mission | ||
centerObject setVariable ["objectArea",[1000, 1000, 0, false, 0]]; | centerObject setVariable ["objectArea",[1000, 1000, 0, false, 0]]; | ||
[ | [centerObject, [], true] call BIS_fnc_moduleCoverMap; | ||
</sqf> | </sqf> | ||
|seealso= [[showMap]] | |seealso= [[showMap]] | ||
}} | }} |
Revision as of 22:16, 13 December 2023
Description
- Description:
-
Covers the map except for a defined area. This function was designed to be used by the Modules framework, but it can also be used without the module. The effect does not move with the centerObject.
- Execution:
- call
- Groups:
- ModulesMap and Markers
Syntax
- Syntax:
- [centerUnit, units, init] call BIS_fnc_moduleCoverMap
- Parameters:
- centerUnit: Object - object which is used as center
- units: Array - Not used inside the function
- init: Boolean - true to create cover map effect, false to remove all markers and destroy the effect
- Return Value:
- Nothing
Examples
- Example 1:
- // covers the whole map except an area of 1000m by 1000m // can be used to dynamically change size of the area during mission centerObject setVariable ["objectArea",[1000, 1000, 0, false, 0]]; [centerObject, [], true] call BIS_fnc_moduleCoverMap;
Additional Information
- See also:
- showMap
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