I don't like generics like this, please change this to just take in an FlxObject, or an FlxSprite. Taking in a T:FlxObject makes Haxe treat the object like a Dynamic type.