BIS fnc sceneAreaClearance: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "|Game version=" to "|Game version= |gr1 = Scenes |GROUP1=")
m (Text replacement - "(Optional, default {{hl|[]}})" to "(Optional, default <sqf inline>[]</sqf>)")
 
(40 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Function|Comments=
{{RV|type=function
____________________________________________________________________________________________


| arma2 |Game name=
|game1= arma2
|version1= 1.00


|1.00|Game version=
|game2= arma2oa
|version2= 1.50


|gr1 = Scenes |GROUP1=
|game3= tkoh
____________________________________________________________________________________________
|version3= 1.00


| Removes object clutter within a set trigger, for use within cutscenes. |DESCRIPTION=
|game4= arma3
____________________________________________________________________________________________
|version4= 0.50


| param spawn [[BIS_fnc_sceneAreaClearance]]; |SYNTAX=
|gr1= Scenes


|p1= [[Object]] - Name of trigger to use as center point.|PARAMETER1=
|descr= Removes object clutter within a set trigger, for use within cutscenes.
|p2= ''[[Array]] - List of objects that will be kept during cutscene. Optional parameter, default empty array.'' |Parameter2=


|p3= ''[[Array]] - Of format [[Position]], where to move all unwanted objects. Optional parameter, default [-5000, 10000, 0].'' |PARAMETER3=
|s1= [trigger, objects, destination] spawn [[BIS_fnc_sceneAreaClearance]]


| [[Nothing]] |RETURNVALUE=
|p1= trigger: [[Object]] - trigger to use as center point
____________________________________________________________________________________________


|x1= <code>0 = [triggerArea1] spawn BIS_fnc_sceneAreaClearance;</code> |EXAMPLE1=
|p2= objects: [[Array]] - (Optional, default <sqf inline>[]</sqf>) list of objects that will be kept during cutscene
____________________________________________________________________________________________


| |SEEALSO=
|p3= destination: [[Array]] in format [[Position]] - (Optional, default [-5000, 10000, 0]) where to move all unwanted objects


|r1= [[Nothing]]
|x1= <sqf>[triggerArea1] spawn BIS_fnc_sceneAreaClearance;</sqf>
|seealso=
}}
}}


<h3 style="display:none">Notes</h3>
<dl class="command_description">
<dl class="command_description">
<!-- Note Section BEGIN -->


<!-- Note Section END -->
<dt></dt>
</dl>
<dd class="notedate">Posted on 2014-10-02 - 16:29 (UTC)</dd>
 
<h3 style="display:none">Bottom Section</h3>
[[Category:Function Group: Scenes|{{uc:sceneAreaClearance}}]]
[[Category:Functions|{{uc:sceneAreaClearance}}]]
[[Category:{{Name|arma2}}: Functions|{{uc:sceneAreaClearance}}]]
[[Category:{{Name|arma2oa}}: Functions|{{uc:sceneAreaClearance}}]]
[[Category:{{Name|tkoh}}: Functions|{{uc:sceneAreaClearance}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:sceneAreaClearance}}]]
 
<!-- CONTINUE Notes -->
<dl class="command_description">
<dd class="notedate">Posted on October 2, 2014 - 16:29 (UTC)</dd>
<dt class="note">[[User:Tryteyker-|Tryteyker-]]</dt>
<dt class="note">[[User:Tryteyker-|Tryteyker-]]</dt>
<dd class="note">
<dd class="note">
In regards to the 'safe position' where the objects get moved, this is how the function handles it (with default values present):
In regards to the 'safe position' where the objects get moved, this is how the function handles it (with default values present):
<sqf>private _savepos = [_unwantedObjectsTempPosition, 0, 100, 20, 0, 60 * (pi / 180), 0] call BIS_fnc_findSafePos;
if ((_savepos distance (getArray (configFile >> "CfgWorlds" >> worldName >> "centerPosition"))) == 0) then
{
_savepos = _unwantedObjectsTempPosition;
};
_x setPos _savepos;
</sqf>
</dd>


<code>
_savepos = [_unwantedObjectsTempPosition, 0, 100, 20, 0, 60 * (pi / 180), 0] call BIS_fnc_findSafePos;
  if((_savepos distance (getArray (configFile >> "CfgWorlds" >> worldName >> "centerPosition"))) = 0) then
  {
    _savepos = _unwantedObjectsTempPosition;
  };
_x setpos _savepos;
</code>
If statement has double equals (comparison statement) but I'm not good enough to actually get wiki formatting right.
</dd>
</dl>
</dl>
<!-- DISCONTINUE Notes -->

Latest revision as of 19:09, 8 November 2023

Hover & click on the images for description

Description

Description:
Removes object clutter within a set trigger, for use within cutscenes.
Execution:
call
Groups:
Scenes

Syntax

Syntax:
[trigger, objects, destination] spawn BIS_fnc_sceneAreaClearance
Parameters:
trigger: Object - trigger to use as center point
objects: Array - (Optional, default []) list of objects that will be kept during cutscene
destination: Array in format Position - (Optional, default [-5000, 10000, 0]) where to move all unwanted objects
Return Value:
Nothing

Examples

Example 1:
[triggerArea1] spawn BIS_fnc_sceneAreaClearance;

Additional Information

See also:
See also needed

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
Posted on 2014-10-02 - 16:29 (UTC)
Tryteyker-
In regards to the 'safe position' where the objects get moved, this is how the function handles it (with default values present):
private _savepos = [_unwantedObjectsTempPosition, 0, 100, 20, 0, 60 * (pi / 180), 0] call BIS_fnc_findSafePos; if ((_savepos distance (getArray (configFile >> "CfgWorlds" >> worldName >> "centerPosition"))) == 0) then { _savepos = _unwantedObjectsTempPosition; }; _x setPos _savepos;