Some cleanup for FlxAnimationController

- use for each loops for better readability / less code
- moved FlxAnimationController.frameSortFunction() to FlxFrame.sort()