Mod.cpp/bin File Format

From Bohemia Interactive Community
Revision as of 17:12, 15 January 2012 by .kju (talk | contribs) (Add CfgMods sample)
Jump to navigation Jump to search

Template:unsupported-doc

A mod.cpp is to offer more detailed information in the expansion menu for mod folders.

Since Operation Arrowhead the root folder of a mod folder can (optionally) contain a mod.bin/cpp. Like arma2\@MyMod\

It is used to provide more details than just '@MyMod' listed on the right side in the main menu.

name = "Cold War Rearmed²";
picture = \some\paafile\somewere.paa;
actionName = "Website";
action = "http://cwr.armedzone.com/";
NOTE: true/false are invalid values in the mod.cpp.

This is the standard method, and quite inconvenient.

An unsatisfactory alternative is to make a pbo with the prefix set to your Mods\ root name. (Which presumes your user's wont change it).

The alternative is a pbo with a config and to define your cfgMods class. BI samples:

class CfgMods
{
	defaultAction = "http://www.arma2.com/mods";
	class Expansion
	{
		dir = "Expansion";
		name = "Arma 2: Operation Arrowhead";
		picture = "ca\ui\data\logo_arma2ep1_ca.paa";
		hidePicture = 0;
		hideName = 1;
		action = "http://www.arma2.com/arrowhead";
	};
	class BAF
	{
		dir = "BAF";
		name = "Arma 2: British Armed Forces (Lite)";
		picture = "ca\data_baf\mod.paa";
		action = "http://www.arma2.com/BAF";
		hash = "BAF v. 1.03";
		hideName = 1;
		actionName = "Buy Now";
		hidePicture = 1;
		islite = 1;
	};
	class PMC
	{
		dir = "PMC";
		picture = "ca\ui\data\logo_arma2pmc_ca.paa";
		hash = "PMC v. 1.02";
		action = "http://www.arma2.com/PMC";
		hideName = 1;
		name = "Arma 2: Private Military Company";
		hidePicture = 0;
	};
};