赞
踩
“ToolTip”脚本具体内容如下:
using UnityEngine;
using UnityEngine.UI;
public class ToolTip : MonoBehaviour {
public Text toolTipText;
public Text toolTipChildText;
public void UpdateTolTip(string content) {
toolTipText.text = content;
toolTipChildText.text = content;
}
public void Show() {
this.gameObject.SetActive(true);
}
public void Hide()
{
this.gameObject.SetActive(false);
}
public void SetLocationPosition(Vector2 position) {
this.transform.localPosition = position;
}
}
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。