I feel like I have been here before, tackling the garage UI and functionality, making everyone’s lives better. I believe this is version 4 or 5 of the garage, but it’s a HUGE part of the game.
The first task has been actually dismantling the current UI system. It was a tangled mess of mixed code, a giant 4,000 line behemoth that handled all the interaction within the Garage menus. I am breaking this down into many different sub-components that will utilizes the internal MAV event system to fire off interaction events to the other components. This allows a much more sane approach to the menus and still maintains the debuggable aspects, since the MAV event system generates proper call stacks, unlike the Unity ‘Send Message’ system.
First on the docket for dismantling, was the ‘Add Part’ menu. First order of business was to snap the whole thing over to the left side of the screen. This allows full screen scrolling, which is very helpful for those 720p screen sizes! Also, by snapping to the left side, I can remove the 3d preview from an embedded menu and instead preview the part right there next to the MAV!
But, how will you see the parts as you are scrolling through the whole list so quickly? 2d image previews! These images all for a quick way to glance at a part as you are scolling through quickly, but you will still get the full ‘in garage’ preview when you hover over one of them.
To make this happen, I had to create a very interesting system. MAV already has a part baking step, as it goes through all the base parts, generates all the final stats and geometry, and then would bake that data out to a database for easy access. Interestingly enough, this entire system is no longer required! It was built around dynamically spawning AI MAV’s and needed to be able to quickly grab all the data about possible parts without having to spawn them. It was also used for the part filtering system. However, in recent updates, the AI have transitioned to using the Skynet system and the part filtering now uses and in-memory data structure, which is much faster anyway. This system was kept around though so it could support the great efforts of the tools at raksal.com [go check them out!].
But, now, it’s back in style! I was able to tap into the part baking process and add a step that would spawn the final part in, position it just right, and grab a nice screen shot with an alpha background. Getting the math correct to properly frame ALL the parts in the same image size likely aged me a few years, but it was worth it. Here is the result:
Of course, there are several other items that will be going into the functionality of the menu, but, no more leaks from me 🙂
In other news, the MAV team has grown by 2 more, bringing the current total up to 6 people, not counting the composer. MattChops already introduced himself on the forums, and he will be ensuring a nice steady stream of content is always going out and that people that create MAV related content are celebrate, highlighted, and even rewarded!
The other new member will be working on making sure lots of secret stuff looks as good as secret stuff can look. You will see more of that around PAX West time!
I also wanted to give community member Tewdrig a big shout out! Tewdrig, due to unlucky circumstances, missed out on the chance to get Alpha Gold camo. His luck seems to have changed as he was the first person to receive an incredibly rare firework drop! Here he is celebrating!
— Tewdrig (@Darragar) July 22, 2017
I will be finishing out this week with more garage work. If you have any garage specific suggestions, drop them in the comments so I have an easy place to reference them! See you next week!
(The cruel thought of tagging this post as a #gs DID cross my mind, as knowing people will be going through all 414 frames of that gif made me chuckle. But I figured this comment, making you wonder if this is a true tag or not, would be more fun 🙂 )