update extension check (#5899)

This commit is contained in:
commy2 2017-12-20 22:41:06 +01:00 committed by PabstMirror
parent ca9448c938
commit 801afb3061
3 changed files with 15 additions and 3 deletions

View File

@ -78,7 +78,17 @@ if (toLower (productVersion select 6) in ["linux", "osx"]) then {
private _versionEx = _x callExtension "version";
if (_versionEx == "") then {
private _errorMsg = format ["Extension %1.dll not installed.", _x];
private _extension = ".dll";
if (productVersion select 7 == "x64") then {
_extension = "_x64.dll";
};
if (productVersion select 6 == "Linux") then {
_extension = ".so";
};
private _errorMsg = format ["Extension %1%2 not found.", _x, _extension];
ERROR(_errorMsg);

View File

@ -10,10 +10,8 @@ GVAR(injuredUnitCollection) = [];
private _versionEx = "ace_medical" callExtension "version";
DFUNC(handleDamage_assignWounds) = if (_versionEx == "") then {
INFO_1("Extension %1.dll not installed.","ace_medical");
DFUNC(handleDamage_woundsOld)
} else {
INFO_2("Extension version: %1: %2","ace_medical",_versionEx);
DFUNC(handleDamage_wounds)
};

View File

@ -54,3 +54,7 @@ class ACE_newEvents {
actionCheckBloodPressureLocal = QGVAR(actionCheckBloodPressureLocal);
addVitalLoop = QGVAR(addVitalLoop);
};
class ACE_Extensions {
extensions[] += {"ace_medical"};
};