Answers for "how to get text mesh pro component"

C#
13

get component text mesh pro

GetComponent<TMPro.TextMeshProUGUI>().text
Posted by: Guest on May-22-2020
2

how to use text mesh pro in script

//needed in order to use Text Mesh Pro
using TMPro; 

public class YourClass : MonoBehaviour
{
	public TextMeshProUGUI InfoText;
    
    public void Something() {
    	//Write to the text mesh pro element InfoText
    	InfoText.text = "Write whatever text you want here!";
    }
}
Posted by: Guest on March-03-2022

C# Answers by Framework

Browse Popular Code Answers by Language