unity textmesh pro get text code example
Example 1: unity textmesh pro
using UnityEngine;
using TMPro;
public class UiManager : MonoBehaviour
{
[SerializeField]
private TextMeshProUGUI TMPtext;
}
Example 2: unity textmeshpro
using UnityEngine;
using TMPro;
public class quizManager : MonoBehaviour
{
public TextMeshProUGUI text;
// Start is called before the first frame update
void Start()
{
text.text = "example";
}
}