This is awesome! I especially loved that you talked about you thought process. “What’s the data that we need to track?” “Who needs to know about the selected category being updated?”
I’m working on an RTS and I’m stumbling over getting the correct set of widgets to display. I think what you did here is a much better solution than what I was doing. I tried repurposing a command pattern I set up for units, and then I had an interface with a function that had a struct as a param, and the struct keeps getting random things added to it as I need them. This looks more promising.
Side note. I had no idea that you could bind a widget’s function to a VM’s array. Blew my mind. I’ve been binding to a delegate, the old school way.
In general thanks! Your other content is great. I use grid box and wrap box and cool things with the common visual attachment when I want to avoid taking up layout space. Never would’ve known about them had you not told me.
“But I’m also considering creating an additional tutorial showing the standard usage of MVVM to represent data and populate our widgets: a deep dive into view bindings, conversion functions and more!”
There’s a few ways to organize, maintain, and deliver learning content. I have a suggestion. There’s a few “Your first 60 minutes with __”. The “Your first 60 minutes with GAS” is a good example. Additionally, the same guy wrote a few following on guides, because you can’t cover everything in 60 minutes. There’s a best practices that covers some edge cases & decisions and a guide on advanced debugging.
What I’m suggesting is a First 60 min with MVVM and CommonUI. With some follow on guides like slate debugging, umg performance profiling, deep dive into whatever floats your boat.
Alternatively, there are no sample projects using MVVM. Cropout, Lyra, ParrotGame, StackOBot, the new templates are not using it. A sample project would be epic. Arran Langmead, Sam, and Sebastian, work for Epic and are always goofing around, and could make a project. A RTS / RPG hybrid project would have a lot of UI things among other stuff.