{"name":"BIS_fnc_moduleCoverMap","operator":null,"title":"BIS fnc moduleCoverMap","type":"function","url":"https://community.bistudio.com/wiki/BIS_fnc_moduleCoverMap","revid":351893,"updated":"2024-01-20T08:51:29Z","groups":["Modules","Map and Markers"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.00"}],"since":{"game":"arma3","name":"Arma 3","version":"1.00"},"arma3_since":"1.00","branch":null,"locality":{"argument":null,"effect":"global","server_exec":false},"exec":null,"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.\n\n> [!IMPORTANT]\n> It is essential for the function to work that **centerObject** has the **objectArea** variable defined.\n>\n> ```sqf\n> centerObject setVariable [\"objectArea\", [sizeX, sizeY, rotation]]\n> ```\n>\n> - centerObject: Object - object which is used as center\n> - sizeX: Number - length in x in meters\n> - sizeY: Number - length in y in meters\n> - rotation: Number - shape's rotation in degree","syntaxes":[{"syntax":"[centerUnit, units, init] call BIS_fnc_moduleCoverMap","since":null,"effect":null,"exec":null,"params":[{"name":"centerUnit","type":"Object","optional":false,"default":null,"description":"object which is used as center","types":["Object"],"since":null,"text":"centerUnit: Object - object which is used as center"},{"name":"units","type":"Array","optional":false,"default":null,"description":"**Not used inside the function**","types":["Array"],"since":null,"text":"units: Array - **Not used inside the function**"},{"name":"init","type":"Boolean","optional":false,"default":null,"description":"true to create cover map effect, false to remove all markers and destroy the effect","types":["Boolean"],"since":null,"text":"init: Boolean - true to create cover map effect, false to remove all markers and destroy the effect"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"}}],"examples":[{"text":"```sqf\n// covers the whole map except an area of 1000m by 1000m\n// can be used to dynamically change size of the area during mission\ncenterObject setVariable [\"objectArea\",[1000, 1000, 0]];    // same format with [[triggerArea]], except the function only needs first three\n[centerObject, [], true] call BIS_fnc_moduleCoverMap;\n```","code":["// covers the whole map except an area of 1000m by 1000m\n// can be used to dynamically change size of the area during mission\ncenterObject setVariable [\"objectArea\",[1000, 1000, 0]];\t// same format with [[triggerArea]], except the function only needs first three\n[centerObject, [], true] call BIS_fnc_moduleCoverMap;"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["showMap"],"notes":[],"categories":["Arma 3: Functions","Arma 3: New Functions","Function Group: Map and Markers","Function Group: Modules","Functions","Functions: Global Effect","Introduced with Arma 3 version 1.00"],"docblock":null,"filled_from_docblock":[]}