Skip to content

Commit

Permalink
xeh rewrite, fix: not all parents being marked as incompatible
Browse files Browse the repository at this point in the history
  • Loading branch information
commy2 committed Dec 31, 2015
1 parent 25d06f4 commit cc39bd1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions addons/xeh/fnc_initPostObject.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ private _class = configFile >> "CfgVehicles" >> typeOf _unit;
while {isClass _class} do {
// call InitPost event handlers
{
// is matching class name if inheritance is disabled and is not a child of any of the excluded classes
if ((_x select 1 || {typeOf _unit isEqualTo configName _class}) && {{_unit isKindOf _x} count (_x select 2) == 0}) then {
if (ISKINDOF(_unit,configName _class,_x select 1,_x select 2)) then {
// prevent variable from being overwritten and causing issues without proper use of private
private _class = nil;

Expand Down
2 changes: 1 addition & 1 deletion addons/xeh/fnc_preInit.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ GVAR(EventsLowercase) = [];
{
private _class = configFile >> "CfgVehicles" >> _x;

while {isClass _class && {!ISINCOMP(_x)}} do {
while {isClass _class && {!ISINCOMP(configName _class)}} do {
SETINCOMP(configName _class);

_class = inheritsFrom _class;
Expand Down

0 comments on commit cc39bd1

Please sign in to comment.