diff --git a/flixel/system/frontEnds/InputFrontEnd.hx b/flixel/system/frontEnds/InputFrontEnd.hx index c1249e5ccf..170e8bc903 100644 --- a/flixel/system/frontEnds/InputFrontEnd.hx +++ b/flixel/system/frontEnds/InputFrontEnd.hx @@ -49,8 +49,13 @@ class InputFrontEnd public function addUniqueType(input:T):T { // Don't add repeat types - if (!Lambda.exists(list, FlxStringUtil.sameClassName.bind(_, input))) - list.push(input); + for (i in list) + { + if (FlxStringUtil.sameClassName(input, i, false)) + { + return input; + } + } return input; }