I’m an artist trying to branch out into coding and game design. i’ve been trying to find more learning materials on UI Toolkit and linking it to existing code. Every article/tutorial seems to deal with adding editor UI elements, or how to build the visual part of the UI.
I’m really struggling to find tutorials and code examples on how to write the C# code to link say a button in a menu to a bool in my game manager. I see quite a few examples showing how to create callbacks so you can display a variable in the UI. that’s great for health or something like ammo left ( i may even re-write my drawpile and discard pile code to use that) but the lack of examples is really hurting. I tried reading the Unity manual on the UI Toolkit.
Can anyone point me to some good learning resources on the UI Toolkit or just some good code examples on how to make the UI interact with your game and not just display variables on screen?