- Home /
I can't drag and drop TextMeshProUGUI from inpector
I've tried to drag and drop a textmeshpro in a script component via inspector but this not allowed, this is my script:
using TMPro;
public class PlayerSetup : MonoBehaviourPunCallbacks
{
[SerializeField]
Text playerNameText;
[SerializeField]
TextMeshProUGUI texto;
// Start is called before the first frame update
void Start()
{
SetPlayerUI();
}
void SetPlayerUI()
{
if (texto != null)
{
texto.text = photonView.Owner.NickName;
}
}
}
Comment