EA Update v0.5.9 - Optimization and Custom Content Error Detection
Highlights
Optimization
Custom Content
Error detection
Optimization
- Using performance profiling tools, we dug deep to identify some bottlenecks and rework code to improve the game's performance, especially for lower-end computers. We’ll be continuing to identify ways we can optimize the game even further going forward. For those of you interested in the technical details, here are some of the improvements we made this time:
- Replaced all Haxe Reflect.hasField() calls with null checks instead where applicable, as the function is known to be slow in most cases.
- Cached animation index lookup for Sprites (previously animation look-ups looped through the whole set to find an animation)
- Internal collision boxes for collisionTestGroup() calls are now recycled to reduce memory allocations (rather than generating temporary boxes every time)
- Refactored stats classes (e.g. AnimationStats, HitboxStats, etc.) so that their import/export logic is baked into the source code rather than dynamically looping to identify valid fields in the classes. - Log message text is no longer drawn to the game live while the console window is hidden. This should prevent the console log window from causing lag during normal gameplay, improving performance in scenarios where the console log is used.
Custom Content
Error detection
- Fixed bug that suppressed error messages for custom content. Content creators will now see applicable error messages in the custom menu and in training mode when using their custom content. You can access the console in training mode by pressing the backtick (`) key.