BIS fnc returnParents: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "(\|[pr][0-9]+ *= *[^- ]*) *- *S([a-z ])" to "$1 - s$2")
m (Text replacement - ">\[ +(.*) *\] +(call|spawn)" to ">[$1] $2")
 
Line 25: Line 25:
|r1= [[Array]] - list of all classes (including starting one)
|r1= [[Array]] - list of all classes (including starting one)


|x1= <sqf>[ configFile >> "CfgVehicles" >> "Land_FirePlace_F", true ] call BIS_fnc_returnParents;
|x1= <sqf>[configFile >> "CfgVehicles" >> "Land_FirePlace_F", true] call BIS_fnc_returnParents;
//Returns ["Land_FirePlace_F","House_F","House","HouseBase","NonStrategic","Building","Static","All"]</sqf>
//Returns ["Land_FirePlace_F","House_F","House","HouseBase","NonStrategic","Building","Static","All"]</sqf>


|seealso= [[configFile]] [[BIS_fnc_returnChildren]]
|seealso= [[configFile]] [[BIS_fnc_returnChildren]]
}}
}}

Latest revision as of 17:27, 8 November 2023

Hover & click on the images for description

Description

Description:
Returns list of all parent classes.
Execution:
call
Groups:
Configs

Syntax

Syntax:
[config, onlyClassNames] call BIS_fnc_returnParents
Parameters:
config: Config - starting config class
onlyClassNames: Boolean - (Optional, default false) true to return only class names
Return Value:
Array - list of all classes (including starting one)

Examples

Example 1:
[configFile >> "CfgVehicles" >> "Land_FirePlace_F", true] call BIS_fnc_returnParents; //Returns ["Land_FirePlace_F","House_F","House","HouseBase","NonStrategic","Building","Static","All"]

Additional Information

See also:
configFile BIS_fnc_returnChildren

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