Search the Community
Showing results for tags 'configfile'.
Found 5 results
-
Good afternoon, I am trying to find information regarding the automatic navigation of the config file. So far I have been doing it 'by hand' by specifying the values in a list of Strings, for example: STWG_PossibleEASTGroups=[ [configfile >> "CfgGroups" >> "East" >> "rhs_faction_vdv" >> "rhs_group_rus_vdv_mi24" >> "rhs_group_rus_vdv_mi24_squad_mg_sniper",0], [configfile >> "CfgGroups" >> "East" >> "rhs_faction_vdv" >> "rhs_group_rus_vdv_mi8" >> "rhs_group_rus_vdv_mi8_squad",0], ... "C_Heli_Light_01_civil_F", "C_IDAP_Heli_Transport_02_F", ... ]; These values are taken from the editor and pasted into the list. I am wondering if it were possible to navigate the config file and obtain those values directly from the script. Thanks in advance.
- 7 replies
-
- configfile
- navigation
-
(and 1 more)
Tagged with:
-
[SOLVED] Return 'GenericNames' from configs.
Maff posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I have been attempting to return a list of first and last names from the configs using the following; _fn = (configfile >> "CfgWorlds" >> "GenericNames" >> "NATOMen" >> "FirstNames"); _ln = (configfile >> "CfgWorlds" >> "GenericNames" >> "NATOMen" >> "LastNames"); Sadly I haven't had any luck as the list of names aren't in an array. I can return names if I already know the name which is... Infuriating! getText (configfile >> "CfgWorlds" >> "GenericNames" >> "NATOMen" >> "FirstNames" >> "aaron_baf") // "Aaron" - What a surprise!! Does anyone have a solution?- 7 replies
-
- 1
-
- genericnames
- names
-
(and 4 more)
Tagged with:
-
Gentlemen, I am looking for a way to pull one array each for Uniforms, vests, backpacks, headgear and so on from configfile, similar to below example for weapons. I would like to pull all equipment items, and then pick out all uniforms or vests or.... (whatever group of items that I want to make an array for) by filtering it by the "parent" name. (eg, below example "if "rifle" in _parents) Now I tried to find the correct parents in config viewer by placing an uniform in eden editor and then rightclick + show in config viewer, but i think i get the wrong parents there (maybe just the vehicle for the placed uniform / "groundweaponholder"?) Anyway none of the parents work and i wonder where i am going the wrong way. For backpacks for example, I selected a backpack from the cfg vehicle list in the config viewer and found the parent "Bag_Base" (or something like that) and it would return an array of backpacks, however, many of the backpacks would contain items. Is there a way to avoid this? In the end I only want each array to contain empty vests/uniforms/backpacks. I think my problem is that I use the wrong method to search for an example classname in config viewer and therefore it provides me with wrong parents. I would appreciate any help or guidance in that respect;) Thanks VD
-
How to get all vehicle classnames ?
SSgt 'Ice Cold' Sykes posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi there, I have issues with my code coming from the fact that i don't really know of to use the configFile and everything that comes with it. I want to return all vehicles including those with "skins". So here is a part of the code i'm trying to use: _allClassNames = []; _Cfg = configFile >> "CfgVehicles"; for "_i" from 0 to (count _Cfg)-1 do { _class = _Cfg select _i; _className = configName _class; _allClassNames pushback _className; }; copyToClipBoard str _allClassNames; /* Extract of _allClassNames: "O_Heli_Transport_04_bench_F", "O_Heli_Transport_04_box_F", ---------------------------- Extract of a list of all class names : "O_Heli_Transport_04_bench_F", "O_Heli_Transport_04_bench_black_F", "O_Heli_Transport_04_box_F", */ I'm clearly missing some vehicles here. (Also how do i get the sqf highlighting when posting code on the forums ?) -
how to use functions in the root of a campaign
boosterchen posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi, Actually i'm working on a campaign. Everthing works pretty well so far, but was thinking to change current structure as I want to move some functions out of the mission folder in order that these can be used by other missions as well without copying them to every mission again. ... that's were the problem started... I tried several ways to achieve that but none of the methods i used seem to work... I am using the standard 'ShowOSD' function. For this, i have created a configfile: cfgFunktion.hpp in 'Campaigns\DM_BST\config' which contains the classes: (cfgFunktion.hpp is included in the description.ext of the current mission: #include "\Campaigns\DM_BST\config\cfgFunktion.hpp" class CfgFunctions { class DM{ class intel { class showOSD { file = "intel\fn_showOSD.sqf"; }; }; }; }; the function fn_showOSD.sqf (which is the standard function of Jiri Wainar) i have it in a subfolder within the the mission folder -> xHub01.Stratis\intel from a customer script (within the missionfolder), the function then gets called using [] spawn DM_fnc_showOSD; So far everthing works as it should! :D but.... when I try to put the function (fn_showOSD.sqf) outside of the missionfolder eg into: Campaigns\DM_BST\functions\intel\ and adopt the path in the cfgFunktion.hpp for the function showOSD to the new location, eg: class showOSD { file = "Campaigns\DM_BST\functions\intel\fn_showOSD.sqf"; }; when I launch the mission the showOSD function dosen't work. Also, what need to be considered when putting something outside of the current missionfolder within a campaign? would really appreciate to get some help here.... Boosterchen- 5 replies
-
- ShowOSD
- cfgFunction.hpp
-
(and 3 more)
Tagged with: