Jump to content

Recommended Posts

please forgve my ignorance, i already searched the forum about this, but no luck.

where i can find a list of the "type" or "class" (dunno whats the correct word) for the item kind ?
i mean like : car, tank, plane  .... what are the others ??
thanks guys!

Share this post


Link to post
Share on other sites

We used to have something lovely called the six config browser, but that's long gone.

 

This is an organised list, but you'll note it's rather out of date. Hopefully, the author will update it, or someone knows of something more recent.

 

http://madbull.arma.free.fr/A3_1.32_CfgVehicles_tree.html

Share this post


Link to post
Share on other sites

nice, thanks!
so, lets say i wish to include everything in a script, men, vehicles and objects.
how should i name them ?

for example:       "allvehicles"        to have all vehicles included?

Share this post


Link to post
Share on other sites

show ur code which should handle men, vehicles and objects, plz.

 

You can get all vehicles with:

vehicles

You get all living units with:

allUnits

Share this post


Link to post
Share on other sites

Well....my code is the "R3F_log" logistic script, hehe, a bit too long to, but the relevant part is very simple,and thanks to your suggestions i already made it work !! Yeeah !

 (Now my problem is to add soldiers too, but its probably related to script because they dont work right now )

Share this post


Link to post
Share on other sites

well the first answer of TANKBUSTER was more or less what i needed!
with that i was able to define my custom list of objects / vehicles kind to add to the script!
as i saied, soldiers not working is probably a problem inside script !

  • Like 1

Share this post


Link to post
Share on other sites
6 hours ago, Tankbuster said:

or someone knows of something more recent

I dumped a CfgVehicles hierarchy HERE back in February, see the output spoiler. There is also some code in that post to output for yourself.

Share this post


Link to post
Share on other sites
2 hours ago, Larrow said:

I dumped a CfgVehicles hierarchy HERE back in February, see the output spoiler. There is also some code in that post to output for yourself.

Spot on!

 

Do you think the code could be made to output HTML? So it could be put on a webserver?

Share this post


Link to post
Share on other sites

Should be pretty easy to just add an unordered list attributes into the text.

 

Spoiler


_hiarachy = [];

_classes = ( "true" configClasses( configFile >> "CfgVehicles" ));
[ "Checking_Classes" ] call BIS_fnc_startLoadingScreen;

{
	_parents = [ _x, true ] call BIS_fnc_returnParents;
	reverse _parents;
	_tree = _hiarachy;

	[ linearConversion[ 0, count _classes, _forEachIndex, 0, 1 ] ] call BIS_fnc_progressLoadingScreen;
	{
		_x params[ "_className" ];
		
		_index = { if ( _x select 0 == _classname )exitWith{ _forEachIndex } }forEach _tree;
		if ( isNil "_index" ) exitWith {
			_index = _tree pushBack [ _classname, [] ];
			_tree = _tree select _index select 1;

			{
				_index = _tree pushBack [ _x, [] ];
				_tree = _tree select _index select 1;

			}forEach ( _parents select[ _forEachIndex +1, count _parents ] );
		};
		_tree = _tree select _index select 1;

	}forEach _parents;
}forEach _classes;
[ "Checking_Classes" ] call BIS_fnc_endLoadingScreen;

[ "format_output" ] call BIS_fnc_startLoadingScreen;
_RETURN = [ 13, 10 ];
_TAB = [ 09 ];

_output = format[ "<!DOCTYPE html>%1<html>%1<body>%1<h2>CfgVehicles</h2><ul>%1", toString _RETURN ];
_tabIndent = 0;

_fnc_addTabs = {
	params[ "_numTabs" ];
	
	_tabs = "";
	for "_i" from 1 to _numTabs do {
		_tabs = formatText[ "%1%2", _tabs, toString _TAB ];
	};
	
	_tabs
};

_fnc_output = {
	params[ "_array" ];
	
	{
		_x params[ "_class", "_derived" ];
		
		_tabs = [ _tabIndent ] call _fnc_addTabs;
		_output = formatText[ "%1%2<li>%3</li>%4", _output, _tabs, _class, toString _RETURN ];
		
		if ( count _derived > 0 ) then {
			_tabIndent = _tabIndent + 1;
			_output = formatText[ "%1%2<ul>%3", _output, _tabs, toString _RETURN ];
			[ _derived ] call _fnc_output;
			_tabIndent = _tabIndent - 1;
			_tabs = [ _tabIndent ] call _fnc_addTabs;
			_output = formatText[ "%1%2</ul>%3", _output, _tabs, toString _RETURN ];
		};
	}forEach _array;
};

[ _hiarachy ] call _fnc_output;
[ "format_output" ] call BIS_fnc_endLoadingScreen;

_output = formatText[ "%1%2</ul>%2</body>%2</html>", _output, toString _RETURN ];

copyToClipboard str _output;

 

And you can test the output HERE

Share this post


Link to post
Share on other sites

I can stop being nice to @sickboy in the hope he might resurrect the much missed six config browser now. :) 

Share this post


Link to post
Share on other sites

maybe someone of you knows it, i'm searching this list but still not found.... what kind of class is a corpse (dead soldier, civilian ecc..)?
thanks !

Share this post


Link to post
Share on other sites
41 minutes ago, dlegion said:

maybe someone of you knows it, i'm searching this list but still not found.... what kind of class is a corpse (dead soldier, civilian ecc..)?
thanks !

you mean like, a config entry has a parent named "corpse" ? 

 

Share this post


Link to post
Share on other sites

you could spawn the man you want dead as AI unit and then set its damage to 1.

  • Like 1

Share this post


Link to post
Share on other sites

hehe, nono its not so simple. i'm working on a script to drag both alive units and corpses, right now i need to name the "class" or "parent class" of the corpses.

Share this post


Link to post
Share on other sites
32 minutes ago, dlegion said:

hehe, nono its not so simple. i'm working on a script to drag both alive units and corpses, right now i need to name the "class" or "parent class" of the corpses.

 

I think you can use a trigger that activates when the player is near a corpse the action for the drag corpse would appear.

 

Cheers

Share this post


Link to post
Share on other sites

perfect!
thanks man !
hope to share my results soon with you all :)

Share this post


Link to post
Share on other sites
Just now, dlegion said:

perfect!
thanks man !
hope to share my results soon with you all :)

 

Glad o be of help :)

 

Seems like when the problem is not mine i know how to solve them lol

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×