Hi Folks,
I’m an absolute Noob, so forgive me in advance for this silly question…
I’m building a small 2D interactive application for my students.
I have 43 UI Buttons (name: keyBtn(a)…(b) etc.) belonging to Canvas.
Each of them has its own tag (A…B…C…) representing letters, numbers and special keys. I have a 2D Text (name: scratchPad) which shall show the final result of the clicked buttons.
-
How to “read” the tag of each of the buttons when I click one of them; in Unity Manual and Script I am not able to find the correct routine to read a tag… I know I am a superNoob… the GetComponent doesn’t work at all for me…
-
I want to store the tag into a string (ok, that’s superSimple) and
-
add this string to the UI Text scratchPad and show it on the screen; practically, to “pass” the string.
Thanks for the help