Merge pull request #852 from Ignatz-HeMan/patch-11

Fix for undefined var on environment Animals
This commit is contained in:
vbawol 2017-09-04 14:03:49 -05:00 committed by GitHub
commit f8297f4d86

View File

@ -33,8 +33,10 @@ _selectedConfig = "";
if (_object isEqualType objNull && !(isNull _object)) then {
if !(_object isKindOf "All") then {
(getModelInfo _object) params [["_modelName",""]];
// replace spaces and periods with underscores
_selectedConfig = (_modelName splitString " .") joinString "_";
if (!isnil "_modelName") then {
// replace spaces and periods with underscores
_selectedConfig = (_modelName splitString " .") joinString "_";
};
} else {
_selectedConfig = typeOf _object;
};