Jump to content
Sign in to follow this  
tachi

Required addons check?

Recommended Posts

Is there a way to check if client has some x,y,z mods loaded? And i'm not talking about signed pbos, im talking about cfgPatches. Is there a way to check if addons that are loaded on the server are exact the same as on the client side, and if client doesn't have all the neccesarry addons, it gets kicked?

Edited by Tachi

Share this post


Link to post
Share on other sites

Like JShock's mention:

defined an array of allowed mods (which could be easier than find some specific mal-mods) then check it on the beginning line of initPlayerLocal.

Share this post


Link to post
Share on other sites

What in theory i need, is an array of all mods from servers CfgPatches basically. Then i need to compare them with the array of mods created from CfgPatches on the client side.

Share this post


Link to post
Share on other sites

Hope this could inspire you in somewhat.

_canPass = true;
{
if (!(["a3_", _x] call BIS_fnc_inString)) then
{
	if (isClass _x) then
	{
		if ((!configName _x) in arrayFromServerAddons) exitWith {_canPass = false;};
	};
};
} forEach activatedAddons;
if (!_canPass) exitWith
{
//do whatever you want.	
};

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
Sign in to follow this  

×