Building an Enterprise App — Creating the UIManager
It’s time to start coding! We’ll begin by creating the UIManager class and attaching it to the UICanvas
We’ll make the UIManager a singleton, if you’ve followed in previous tutorials, this will be very familiar now!
Now we’ll add some functionality to our UIManager, if we create a new Case type and make it public, it will appear in our Canvas’s UI Manager!
I filled it out with fake info for fun, also note you can create an array or list of cases using the brackets [] or greater/less than symbols <>, but that’s a lesson for another time. Finally, we’ll add a script for the create case button that will take advantage of our current activeCase variable.
We’ll attach it to our button and try it out:
It’s blanked out our fake info meaning that we now have a brand spankin’ new activeCase waiting to be filled out and used!