unity textmesh pro in script code example
Example 1: unity textmesh pro
using UnityEngine;
using TMPro;
public class UiManager : MonoBehaviour
{
[SerializeField]
private TextMeshProUGUI TMPtext;
}
Example 2: unity get textmesh pro component
GetComponent<TMPro.TextMeshProUGUI>().text