1.在Unity中给字体设置颜色:
2.用代码附值:
如果选好颜色不知道rgba的值,可以在代码中打印一下;
debug.Log( Lidnumber.GetComponent<Text>().color);
接着用代码给文本赋值:
Lidnumber.GetComponent<Text>().color = new Color(0.801f,0.784f,0.784f,0.947f);
1.在Unity中给字体设置颜色:
2.用代码附值:
如果选好颜色不知道rgba的值,可以在代码中打印一下;
debug.Log( Lidnumber.GetComponent<Text>().color);
接着用代码给文本赋值:
Lidnumber.GetComponent<Text>().color = new Color(0.801f,0.784f,0.784f,0.947f);